diff options
Diffstat (limited to 'demos')
29 files changed, 131 insertions, 131 deletions
diff --git a/demos/constraint-editor/constraint-editor-application.c b/demos/constraint-editor/constraint-editor-application.c index ca65cb695d..0eef96ac38 100644 --- a/demos/constraint-editor/constraint-editor-application.c +++ b/demos/constraint-editor/constraint-editor-application.c @@ -82,7 +82,7 @@ static void constraint_editor_application_open (GApplication *app, GFile **files, int n_files, - const gchar *hint) + const char *hint) { ConstraintEditorWindow *win; int i; diff --git a/demos/gtk-demo/application.c b/demos/gtk-demo/application.c index 2b5e8e094a..801b728a40 100644 --- a/demos/gtk-demo/application.c +++ b/demos/gtk-demo/application.c @@ -34,7 +34,7 @@ static void create_window (GApplication *app, const char *contents); static void show_action_dialog (GSimpleAction *action) { - const gchar *name; + const char *name; GtkWidget *dialog; name = g_action_get_name (G_ACTION (action)); @@ -58,9 +58,9 @@ show_action_infobar (GSimpleAction *action, gpointer data) { DemoApplicationWindow *window = data; - gchar *text; - const gchar *name; - const gchar *value; + char *text; + const char *name; + const char *value; name = g_action_get_name (G_ACTION (action)); value = g_variant_get_string (parameter, NULL); @@ -185,7 +185,7 @@ activate_about (GSimpleAction *action, { GtkWidget *window = user_data; - const gchar *authors[] = { + const char *authors[] = { "Peter Mattis", "Spencer Kimball", "Josh MacDonald", @@ -193,7 +193,7 @@ activate_about (GSimpleAction *action, NULL }; - const gchar *documentors[] = { + const char *documentors[] = { "Owen Taylor", "Tony Gale", "Matthias Clasen <mclasen@redhat.com>", @@ -244,7 +244,7 @@ static void update_statusbar (GtkTextBuffer *buffer, DemoApplicationWindow *window) { - gchar *msg; + char *msg; int row, col; int count; GtkTextIter iter; diff --git a/demos/gtk-demo/application_demo.c b/demos/gtk-demo/application_demo.c index 087ea3ff8f..987ef0dab3 100644 --- a/demos/gtk-demo/application_demo.c +++ b/demos/gtk-demo/application_demo.c @@ -16,8 +16,8 @@ static GtkWidget *placeholder; static void on_name_appeared (GDBusConnection *connection, - const gchar *name, - const gchar *name_owner, + const char *name, + const char *name_owner, gpointer user_data) { name_seen = TRUE; @@ -25,7 +25,7 @@ on_name_appeared (GDBusConnection *connection, static void on_name_vanished (GDBusConnection *connection, - const gchar *name, + const char *name, gpointer user_data) { if (!name_seen) @@ -55,7 +55,7 @@ do_application_demo (GtkWidget *toplevel) if (placeholder == NULL) { - const gchar *command; + const char *command; GError *error = NULL; if (g_file_test ("./gtk4-demo-application" APP_EXTENSION, G_FILE_TEST_IS_EXECUTABLE)) diff --git a/demos/gtk-demo/assistant.c b/demos/gtk-demo/assistant.c index b90e42ab55..d3f3780a6b 100644 --- a/demos/gtk-demo/assistant.c +++ b/demos/gtk-demo/assistant.c @@ -48,7 +48,7 @@ static void on_assistant_prepare (GtkWidget *widget, GtkWidget *page, gpointer data) { int current_page, n_pages; - gchar *title; + char *title; current_page = gtk_assistant_get_current_page (GTK_ASSISTANT (widget)); n_pages = gtk_assistant_get_n_pages (GTK_ASSISTANT (widget)); @@ -71,7 +71,7 @@ on_entry_changed (GtkWidget *widget, gpointer data) GtkAssistant *assistant = GTK_ASSISTANT (data); GtkWidget *current_page; int page_number; - const gchar *text; + const char *text; page_number = gtk_assistant_get_current_page (assistant); current_page = gtk_assistant_get_nth_page (assistant, page_number); diff --git a/demos/gtk-demo/css_blendmodes.c b/demos/gtk-demo/css_blendmodes.c index 5efd3cf32b..0543750d9c 100644 --- a/demos/gtk-demo/css_blendmodes.c +++ b/demos/gtk-demo/css_blendmodes.c @@ -38,14 +38,14 @@ struct { #pragma GCC diagnostic ignored "-Wformat-nonliteral" static void update_css_for_blend_mode (GtkCssProvider *provider, - const gchar *blend_mode) + const char *blend_mode) { GBytes *bytes; - gchar *css; + char *css; bytes = g_resources_lookup_data ("/css_blendmodes/css_blendmodes.css", 0, NULL); - css = g_strdup_printf ((gchar*) g_bytes_get_data (bytes, NULL), + css = g_strdup_printf ((char *) g_bytes_get_data (bytes, NULL), blend_mode, blend_mode, blend_mode); @@ -62,7 +62,7 @@ row_activated (GtkListBox *listbox, GtkListBoxRow *row, GtkCssProvider *provider) { - const gchar *blend_mode; + const char *blend_mode; blend_mode = blend_modes[gtk_list_box_row_get_index (row)].id; diff --git a/demos/gtk-demo/demoimage.c b/demos/gtk-demo/demoimage.c index 37c0acd684..40acbd2dce 100644 --- a/demos/gtk-demo/demoimage.c +++ b/demos/gtk-demo/demoimage.c @@ -17,7 +17,7 @@ G_DEFINE_TYPE(DemoImage, demo_image, GTK_TYPE_WIDGET) static GdkPaintable * get_image_paintable (GtkImage *image) { - const gchar *icon_name; + const char *icon_name; GtkIconTheme *icon_theme; GtkIconPaintable *icon; diff --git a/demos/gtk-demo/editable_cells.c b/demos/gtk-demo/editable_cells.c index 0cc307b160..cd1fc9be3c 100644 --- a/demos/gtk-demo/editable_cells.c +++ b/demos/gtk-demo/editable_cells.c @@ -17,7 +17,7 @@ typedef struct { int number; - gchar *product; + char *product; int yummy; } Item; @@ -224,7 +224,7 @@ separator_row (GtkTreeModel *model, static void editing_started (GtkCellRenderer *cell, GtkCellEditable *editable, - const gchar *path, + const char *path, gpointer data) { gtk_combo_box_set_row_separator_func (GTK_COMBO_BOX (editable), @@ -233,8 +233,8 @@ editing_started (GtkCellRenderer *cell, static void cell_edited (GtkCellRendererText *cell, - const gchar *path_string, - const gchar *new_text, + const char *path_string, + const char *new_text, gpointer data) { GtkTreeModel *model = (GtkTreeModel *)data; @@ -262,7 +262,7 @@ cell_edited (GtkCellRendererText *cell, case COLUMN_ITEM_PRODUCT: { int i; - gchar *old_text; + char *old_text; gtk_tree_model_get (model, &iter, column, &old_text, -1); g_free (old_text); diff --git a/demos/gtk-demo/filtermodel.c b/demos/gtk-demo/filtermodel.c index b1492c71ca..85180372ee 100644 --- a/demos/gtk-demo/filtermodel.c +++ b/demos/gtk-demo/filtermodel.c @@ -23,7 +23,7 @@ format_number (GtkTreeViewColumn *col, gpointer data) { int num; - gchar *text; + char *text; gtk_tree_model_get (model, iter, GPOINTER_TO_INT (data), &num, -1); text = g_strdup_printf ("%d", num); diff --git a/demos/gtk-demo/flowbox.c b/demos/gtk-demo/flowbox.c index 2673e35d08..df7d6f3905 100644 --- a/demos/gtk-demo/flowbox.c +++ b/demos/gtk-demo/flowbox.c @@ -29,7 +29,7 @@ draw_color (GtkDrawingArea *drawingarea, } static GtkWidget * -color_swatch_new (const gchar *color) +color_swatch_new (const char *color) { GtkWidget *button, *area; @@ -48,7 +48,7 @@ do_flowbox (GtkWidget *do_widget) { static GtkWidget *window = NULL; GtkWidget *scrolled, *flowbox; - const gchar *colors[] = { + const char *colors[] = { "AliceBlue", "AntiqueWhite", "AntiqueWhite1", diff --git a/demos/gtk-demo/font_features.c b/demos/gtk-demo/font_features.c index 09ca986764..0e7a3cf333 100644 --- a/demos/gtk-demo/font_features.c +++ b/demos/gtk-demo/font_features.c @@ -729,7 +729,7 @@ entry_activated (GtkEntry *entry, GtkAdjustment *adjustment) { gdouble value; - gchar *err = NULL; + char *err = NULL; value = g_strtod (gtk_editable_get_text (GTK_EDITABLE (entry)), &err); if (err != NULL) diff --git a/demos/gtk-demo/iconview.c b/demos/gtk-demo/iconview.c index cd462de844..030e9a896a 100644 --- a/demos/gtk-demo/iconview.c +++ b/demos/gtk-demo/iconview.c @@ -25,7 +25,7 @@ enum static GdkPixbuf *file_pixbuf, *folder_pixbuf; -gchar *parent; +char *parent; GtkWidget *up_button; /* Loads the images for the demo and returns whether the operation succeeded */ @@ -47,7 +47,7 @@ static void fill_store (GtkListStore *store) { GDir *dir; - const gchar *name; + const char *name; GtkTreeIter iter; /* First clear the store */ @@ -62,7 +62,7 @@ fill_store (GtkListStore *store) name = g_dir_read_name (dir); while (name != NULL) { - gchar *path, *display_name; + char *path, *display_name; gboolean is_dir; /* We ignore hidden files that start with a '.' */ @@ -97,7 +97,7 @@ sort_func (GtkTreeModel *model, gpointer user_data) { gboolean is_dir_a, is_dir_b; - gchar *name_a, *name_b; + char *name_a, *name_b; int ret; /* We need this function because we want to sort @@ -158,7 +158,7 @@ item_activated (GtkIconView *icon_view, gpointer user_data) { GtkListStore *store; - gchar *path; + char *path; GtkTreeIter iter; gboolean is_dir; @@ -192,7 +192,7 @@ up_clicked (GtkButton *item, gpointer user_data) { GtkListStore *store; - gchar *dir_name; + char *dir_name; store = GTK_LIST_STORE (user_data); diff --git a/demos/gtk-demo/iconview_edit.c b/demos/gtk-demo/iconview_edit.c index 6225230a64..69e6184055 100644 --- a/demos/gtk-demo/iconview_edit.c +++ b/demos/gtk-demo/iconview_edit.c @@ -19,7 +19,7 @@ static void fill_store (GtkListStore *store) { GtkTreeIter iter; - const gchar *text[] = { "Red", "Green", "Blue", "Yellow" }; + const char *text[] = { "Red", "Green", "Blue", "Yellow" }; int i; /* First clear the store */ @@ -49,7 +49,7 @@ set_cell_color (GtkCellLayout *cell_layout, GtkTreeIter *iter, gpointer data) { - gchar *text; + char *text; GdkRGBA color; guint32 pixel = 0; GdkPixbuf *pixbuf; @@ -77,8 +77,8 @@ set_cell_color (GtkCellLayout *cell_layout, static void edited (GtkCellRendererText *cell, - gchar *path_string, - gchar *text, + char *path_string, + char *text, gpointer data) { GtkTreeModel *model; diff --git a/demos/gtk-demo/links.c b/demos/gtk-demo/links.c index b8afd56638..8655b8a23a 100644 --- a/demos/gtk-demo/links.c +++ b/demos/gtk-demo/links.c @@ -17,7 +17,7 @@ response_cb (GtkWidget *dialog, static gboolean activate_link (GtkWidget *label, - const gchar *uri, + const char *uri, gpointer data) { if (g_strcmp0 (uri, "keynav") == 0) diff --git a/demos/gtk-demo/main.c b/demos/gtk-demo/main.c index aea46e21ea..e8aa1ab93a 100644 --- a/demos/gtk-demo/main.c +++ b/demos/gtk-demo/main.c @@ -13,7 +13,7 @@ static GtkWidget *info_view; static GtkWidget *source_view; -static gchar *current_file = NULL; +static char *current_file = NULL; static GtkWidget *notebook; static GtkSingleSelection *selection; @@ -141,7 +141,7 @@ activate_about (GSimpleAction *action, gpointer user_data) { GtkApplication *app = user_data; - const gchar *authors[] = { + const char *authors[] = { "The GTK Team", NULL }; @@ -254,7 +254,7 @@ static const char *types[] = "void", " int ", " char ", - "gchar ", + "char ", "gfloat", "float", "double", @@ -384,14 +384,14 @@ static const char *control[] = NULL }; void -parse_chars (gchar *text, - gchar **end_ptr, +parse_chars (char *text, + char **end_ptr, int *state, const char **tag, gboolean start) { int i; - gchar *next_token; + char *next_token; /* Handle comments first */ if (*state == STATE_IN_COMMENT) @@ -525,8 +525,8 @@ fontify (GtkTextBuffer *source_buffer) { GtkTextIter start_iter, next_iter, tmp_iter; int state; - gchar *text; - gchar *start_ptr, *end_ptr; + char *text; + char *start_ptr, *end_ptr; const char *tag; gtk_text_buffer_create_tag (source_buffer, "source", @@ -694,10 +694,10 @@ static struct { }; static void -add_data_tab (const gchar *demoname) +add_data_tab (const char *demoname) { - gchar *resource_dir, *resource_name; - gchar **resources; + char *resource_dir, *resource_name; + char **resources; GtkWidget *widget, *label; guint i, j; @@ -748,8 +748,8 @@ remove_data_tabs (void) } void -load_file (const gchar *demoname, - const gchar *filename) +load_file (const char *demoname, + const char *filename) { GtkTextBuffer *info_buffer, *source_buffer; GtkTextIter start, end; @@ -757,7 +757,7 @@ load_file (const gchar *demoname, GError *err = NULL; int state = 0; gboolean in_para = 0; - gchar **lines; + char **lines; GBytes *bytes; int i; @@ -799,9 +799,9 @@ load_file (const gchar *demoname, gtk_text_buffer_get_iter_at_offset (info_buffer, &start, 0); for (i = 0; lines[i] != NULL; i++) { - gchar *p; - gchar *q; - gchar *r; + char *p; + char *q; + char *r; /* Make sure \r is stripped at the end for the poor windows people */ lines[i] = g_strchomp (lines[i]); @@ -1194,7 +1194,7 @@ command_line (GApplication *app, GApplicationCommandLine *cmdline) { GVariantDict *options; - const gchar *name = NULL; + const char *name = NULL; gboolean autoquit = FALSE; gboolean list = FALSE; DemoData *d, *c; @@ -1297,8 +1297,8 @@ main (int argc, char **argv) { "inspector", activate_inspector, NULL, NULL, NULL }, }; struct { - const gchar *action_and_target; - const gchar *accelerators[2]; + const char *action_and_target; + const char *accelerators[2]; } accels[] = { { "app.about", { "F1", NULL } }, { "app.quit", { "<Control>q", NULL } }, diff --git a/demos/gtk-demo/markup.c b/demos/gtk-demo/markup.c index 671fb5c92d..6648d508f3 100644 --- a/demos/gtk-demo/markup.c +++ b/demos/gtk-demo/markup.c @@ -21,7 +21,7 @@ source_toggled (GtkToggleButton *button) { GtkTextBuffer *buffer; GtkTextIter start, end; - gchar *markup; + char *markup; buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view2)); gtk_text_buffer_get_bounds (buffer, &start, &end); @@ -50,7 +50,7 @@ do_markup (GtkWidget *do_widget) GtkTextBuffer *buffer; GtkTextIter iter; GBytes *bytes; - const gchar *markup; + const char *markup; GtkWidget *header; GtkWidget *show_source; @@ -102,7 +102,7 @@ do_markup (GtkWidget *do_widget) gtk_stack_add_named (GTK_STACK (stack), sw, "source"); bytes = g_resources_lookup_data ("/markup/markup.txt", 0, NULL); - markup = (const gchar *)g_bytes_get_data (bytes, NULL); + markup = (const char *)g_bytes_get_data (bytes, NULL); buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view)); gtk_text_buffer_get_start_iter (buffer, &iter); diff --git a/demos/gtk-demo/paint.c b/demos/gtk-demo/paint.c index 8717330276..d3e6c59cf1 100644 --- a/demos/gtk-demo/paint.c +++ b/demos/gtk-demo/paint.c @@ -38,7 +38,7 @@ static GtkPadActionEntry pad_actions[] = { { GTK_PAD_ACTION_STRIP, -1, -1, N_("Brush size"), "pad.brush_size" }, }; -static const gchar *pad_colors[] = { +static const char *pad_colors[] = { "black", "pink", "green", @@ -154,7 +154,7 @@ on_pad_button_activate (GSimpleAction *action, GVariant *parameter, DrawingArea *area) { - const gchar *color = g_object_get_data (G_OBJECT (action), "color"); + const char *color = g_object_get_data (G_OBJECT (action), "color"); GdkRGBA rgba; gdk_rgba_parse (&rgba, color); diff --git a/demos/gtk-demo/panes.c b/demos/gtk-demo/panes.c index e756a181e3..134d3bea97 100644 --- a/demos/gtk-demo/panes.c +++ b/demos/gtk-demo/panes.c @@ -47,9 +47,9 @@ toggle_shrink (GtkWidget *widget, static GtkWidget * create_pane_options (GtkPaned *paned, - const gchar *frame_label, - const gchar *label1, - const gchar *label2) + const char *frame_label, + const char *label1, + const char *label2) { GtkWidget *child1, *child2; GtkWidget *frame; diff --git a/demos/gtk-demo/printing.c b/demos/gtk-demo/printing.c index 96232db40f..5dd0ed493b 100644 --- a/demos/gtk-demo/printing.c +++ b/demos/gtk-demo/printing.c @@ -14,11 +14,11 @@ typedef struct { - gchar *resourcename; + char *resourcename; gdouble font_size; int lines_per_page; - gchar **lines; + char **lines; int num_lines; int num_pages; } PrintData; @@ -65,7 +65,7 @@ draw_page (GtkPrintOperation *operation, gdouble width; int line, i; PangoFontDescription *desc; - gchar *page_str; + char *page_str; cr = gtk_print_context_get_cairo_context (context); width = gtk_print_context_get_width (context); diff --git a/demos/gtk-demo/revealer.c b/demos/gtk-demo/revealer.c index c3ed6b4cdd..e4e94a8536 100644 --- a/demos/gtk-demo/revealer.c +++ b/demos/gtk-demo/revealer.c @@ -25,7 +25,7 @@ static gboolean reveal_one (gpointer data) { GtkWidget *window = data; - gchar *name; + char *name; GtkRevealer *revealer; name = g_strdup_printf ("revealer%d", count); diff --git a/demos/gtk-demo/shortcuts.c b/demos/gtk-demo/shortcuts.c index 941ef77481..7dcfe8fd42 100644 --- a/demos/gtk-demo/shortcuts.c +++ b/demos/gtk-demo/shortcuts.c @@ -8,12 +8,12 @@ static void show_shortcuts (GtkWidget *window, - const gchar *id, - const gchar *view) + const char *id, + const char *view) { GtkBuilder *builder; GtkWidget *overlay; - gchar *path; + char *path; path = g_strdup_printf ("/shortcuts/%s.ui", id); builder = gtk_builder_new_from_resource (path); diff --git a/demos/gtk-demo/sidebar.c b/demos/gtk-demo/sidebar.c index 714978a1a2..c7ca861b55 100644 --- a/demos/gtk-demo/sidebar.c +++ b/demos/gtk-demo/sidebar.c @@ -18,7 +18,7 @@ do_sidebar (GtkWidget *do_widget) GtkWidget *box; GtkWidget *widget; GtkWidget *header; - const gchar* pages[] = { + const char * pages[] = { "Welcome to GTK", "GtkStackSidebar Widget", "Automatic navigation", @@ -30,7 +30,7 @@ do_sidebar (GtkWidget *do_widget) "Page 9", NULL }; - const gchar *c = NULL; + const char *c = NULL; guint i; if (!window) diff --git a/demos/gtk-demo/spinbutton.c b/demos/gtk-demo/spinbutton.c index e00dfb87de..da41f04407 100644 --- a/demos/gtk-demo/spinbutton.c +++ b/demos/gtk-demo/spinbutton.c @@ -15,8 +15,8 @@ int spinbutton_hex_spin_input (GtkSpinButton *spin_button, gdouble *new_val) { - const gchar *buf; - gchar *err; + const char *buf; + char *err; gdouble res; buf = gtk_editable_get_text (GTK_EDITABLE (spin_button)); @@ -32,7 +32,7 @@ int spinbutton_hex_spin_output (GtkSpinButton *spin_button) { GtkAdjustment *adjustment; - gchar *buf; + char *buf; gdouble val; adjustment = gtk_spin_button_get_adjustment (spin_button); @@ -52,13 +52,13 @@ int spinbutton_time_spin_input (GtkSpinButton *spin_button, gdouble *new_val) { - const gchar *text; - gchar **str; + const char *text; + char **str; gboolean found = FALSE; int hours; int minutes; - gchar *endh; - gchar *endm; + char *endh; + char *endm; text = gtk_editable_get_text (GTK_EDITABLE (spin_button)); str = g_strsplit (text, ":", 2); @@ -91,7 +91,7 @@ int spinbutton_time_spin_output (GtkSpinButton *spin_button) { GtkAdjustment *adjustment; - gchar *buf; + char *buf; gdouble hours; gdouble minutes; @@ -126,7 +126,7 @@ spinbutton_month_spin_input (GtkSpinButton *spin_button, gdouble *new_val) { int i; - gchar *tmp1, *tmp2; + char *tmp1, *tmp2; gboolean found = FALSE; for (i = 1; i <= 12; i++) diff --git a/demos/gtk-demo/tree_store.c b/demos/gtk-demo/tree_store.c index a15dbab32a..4514aceec9 100644 --- a/demos/gtk-demo/tree_store.c +++ b/demos/gtk-demo/tree_store.c @@ -14,7 +14,7 @@ typedef struct _TreeItem TreeItem; struct _TreeItem { - const gchar *label; + const char *label; gboolean alex; gboolean havoc; gboolean tim; @@ -222,7 +222,7 @@ create_model (void) static void item_toggled (GtkCellRendererToggle *cell, - gchar *path_str, + char *path_str, gpointer data) { GtkTreeModel *model = (GtkTreeModel *)data; diff --git a/demos/icon-browser/iconbrowserapp.c b/demos/icon-browser/iconbrowserapp.c index f5b7c76844..31466c73dc 100644 --- a/demos/icon-browser/iconbrowserapp.c +++ b/demos/icon-browser/iconbrowserapp.c @@ -43,7 +43,7 @@ about_activated (GSimpleAction *action, gpointer user_data) { GtkApplication *app = user_data; - const gchar *authors[] = { + const char *authors[] = { "The GTK Team", NULL }; @@ -103,7 +103,7 @@ static GActionEntry app_entries[] = static void icon_browser_app_startup (GApplication *app) { - const gchar *quit_accels[2] = { "<Ctrl>Q", NULL }; + const char *quit_accels[2] = { "<Ctrl>Q", NULL }; G_APPLICATION_CLASS (icon_browser_app_parent_class)->startup (app); diff --git a/demos/icon-browser/iconbrowserwin.c b/demos/icon-browser/iconbrowserwin.c index b276fdd142..700d8381f9 100644 --- a/demos/icon-browser/iconbrowserwin.c +++ b/demos/icon-browser/iconbrowserwin.c @@ -44,13 +44,13 @@ icon_browser_window_get_icon_theme (IconBrowserWindow *win) static void add_icon (IconBrowserWindow *win, - const gchar *name, - const gchar *description, - const gchar *context) + const char *name, + const char *description, + const char *context) { GtkIconTheme *icon_theme = icon_browser_window_get_icon_theme (win); - gchar *regular_name; - gchar *symbolic_name; + char *regular_name; + char *symbolic_name; IbIcon *icon; regular_name = g_strdup (name); @@ -77,9 +77,9 @@ add_icon (IconBrowserWindow *win, static void add_context (IconBrowserWindow *win, - const gchar *id, - const gchar *name, - const gchar *description) + const char *id, + const char *name, + const char *description) { IbContext *context; @@ -161,7 +161,7 @@ copy_to_clipboard (GtkButton *button, } static void -set_image (GtkWidget *image, const gchar *name, int size) +set_image (GtkWidget *image, const char *name, int size) { gtk_image_set_from_icon_name (GTK_IMAGE (image), name); gtk_image_set_pixel_size (GTK_IMAGE (image), size); @@ -219,7 +219,7 @@ item_activated (GtkGridView *view, static GdkPaintable * get_image_paintable (GtkImage *image) { - const gchar *icon_name; + const char *icon_name; GtkIconTheme *icon_theme; GtkIconPaintable *icon; int size; diff --git a/demos/node-editor/node-editor-application.c b/demos/node-editor/node-editor-application.c index 6fefa60b7a..ca5ef04e41 100644 --- a/demos/node-editor/node-editor-application.c +++ b/demos/node-editor/node-editor-application.c @@ -200,7 +200,7 @@ static void node_editor_application_open (GApplication *app, GFile **files, int n_files, - const gchar *hint) + const char *hint) { NodeEditorWindow *win; int i; diff --git a/demos/node-editor/node-editor-window.c b/demos/node-editor/node-editor-window.c index 7b20364496..1e88395385 100644 --- a/demos/node-editor/node-editor-window.c +++ b/demos/node-editor/node-editor-window.c @@ -80,7 +80,7 @@ text_view_error_free (TextViewError *e) g_free (e->message); } -static gchar * +static char * get_current_text (GtkTextBuffer *buffer) { GtkTextIter start, end; diff --git a/demos/print-editor/print-editor.c b/demos/print-editor/print-editor.c index 69a5819ae3..4bd88b0c4a 100644 --- a/demos/print-editor/print-editor.c +++ b/demos/print-editor/print-editor.c @@ -33,7 +33,7 @@ update_title (GtkWindow *window) static void update_statusbar (void) { - gchar *msg; + char *msg; int row, col; GtkTextIter iter; const char *print_str; @@ -675,7 +675,7 @@ static GActionEntry app_entries[] = { { "print", activate_print, NULL, NULL, NULL } }; -static const gchar ui_info[] = +static const char ui_info[] = "<interface>" " <menu id='menubar'>" " <submenu>" diff --git a/demos/widget-factory/widget-factory.c b/demos/widget-factory/widget-factory.c index f48a906e1b..90915f6b70 100644 --- a/demos/widget-factory/widget-factory.c +++ b/demos/widget-factory/widget-factory.c @@ -250,12 +250,12 @@ activate_about (GSimpleAction *action, gpointer user_data) { GtkApplication *app = user_data; - const gchar *authors[] = { + const char *authors[] = { "Andrea Cimitan", "Cosimo Cecchi", NULL }; - gchar *version; + char *version; GString *s; s = g_string_new (""); @@ -423,7 +423,7 @@ spin_value_changed (GtkAdjustment *adjustment, GtkWidget *label) { GtkWidget *w; int v; - gchar *text; + char *text; v = (int)gtk_adjustment_get_value (adjustment); @@ -542,7 +542,7 @@ on_scale_button_value_changed (GtkScaleButton *button, { GtkAdjustment *adjustment; gdouble val; - gchar *str; + char *str; adjustment = gtk_scale_button_get_adjustment (button); val = gtk_scale_button_get_value (button); @@ -703,7 +703,7 @@ action_dialog_button_clicked (GtkButton *button, GtkWidget *page) static void page_changed_cb (GtkWidget *stack, GParamSpec *pspec, gpointer data) { - const gchar *name; + const char *name; GtkWidget *window; GtkWidget *page; @@ -853,10 +853,10 @@ update_title_header (GtkListBoxRow *row, gpointer data) { GtkWidget *header; - gchar *title; + char *title; header = gtk_list_box_row_get_header (row); - title = (gchar *)g_object_get_data (G_OBJECT (row), "title"); + title = (char *)g_object_get_data (G_OBJECT (row), "title"); if (!header && title) { title = g_strdup_printf ("<b>%s</b>", title); @@ -881,8 +881,8 @@ overshot (GtkScrolledWindow *sw, GtkPositionType pos, GtkWidget *widget) { GtkWidget *box, *row, *label, *swatch; GdkRGBA rgba; - const gchar *color; - gchar *text; + const char *color; + char *text; GtkWidget *silver; GtkWidget *gold; @@ -983,7 +983,7 @@ set_color (GtkListBox *box, GtkListBoxRow *row, GtkColorChooser *chooser) static void populate_colors (GtkWidget *widget, GtkWidget *chooser) { - struct { const gchar *name; const gchar *color; const gchar *title; } colors[] = { + struct { const char *name; const char *color; const char *title; } colors[] = { { "2.5", "#C8828C", "Red" }, { "5", "#C98286", NULL }, { "7.5", "#C9827F", NULL }, @@ -1081,7 +1081,7 @@ populate_colors (GtkWidget *widget, GtkWidget *chooser) typedef struct { GtkWidget *flowbox; - gchar *filename; + char *filename; } BackgroundData; static void @@ -1127,11 +1127,11 @@ background_loaded_cb (GObject *source, static void populate_flowbox (GtkWidget *flowbox) { - const gchar *location; + const char *location; GDir *dir; GError *error = NULL; - const gchar *name; - gchar *filename; + const char *name; + char *filename; GFile *file; GInputStream *stream; BackgroundData *bd; @@ -1288,7 +1288,7 @@ my_text_view_class_init (MyTextViewClass *class) } static void -my_text_view_set_background (MyTextView *tv, const gchar *filename, gboolean is_resource) +my_text_view_set_background (MyTextView *tv, const char *filename, gboolean is_resource) { GError *error = NULL; GFile *file; @@ -1336,7 +1336,7 @@ close_selection_dialog (GtkWidget *dialog, int response, GtkWidget *tv) GtkWidget *box; GtkWidget *child; GList *children; - const gchar *filename; + const char *filename; gboolean is_resource; gtk_widget_hide (dialog); @@ -1352,7 +1352,7 @@ close_selection_dialog (GtkWidget *dialog, int response, GtkWidget *tv) return; child = children->data; - filename = (const gchar *)g_object_get_data (G_OBJECT (child), "filename"); + filename = (const char *)g_object_get_data (G_OBJECT (child), "filename"); is_resource = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (child), "is-resource")); g_list_free (children); @@ -1377,8 +1377,8 @@ static void handle_insert (GtkWidget *button, GtkWidget *textview) { GtkTextBuffer *buffer; - const gchar *id; - const gchar *text; + const char *id; + const char *text; id = gtk_buildable_get_name (GTK_BUILDABLE (button)); @@ -1402,7 +1402,7 @@ handle_cutcopypaste (GtkWidget *button, GtkWidget *textview) { GtkTextBuffer *buffer; GdkClipboard *clipboard; - const gchar *id; + const char *id; clipboard = gtk_widget_get_clipboard (textview); buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (textview)); @@ -1421,7 +1421,7 @@ handle_cutcopypaste (GtkWidget *button, GtkWidget *textview) static void clipboard_formats_notify (GdkClipboard *clipboard, GdkEvent *event, GtkWidget *button) { - const gchar *id; + const char *id; gboolean has_text; id = gtk_buildable_get_name (GTK_BUILDABLE (button)); @@ -1434,7 +1434,7 @@ clipboard_formats_notify (GdkClipboard *clipboard, GdkEvent *event, GtkWidget *b static void textbuffer_notify_selection (GObject *object, GParamSpec *pspec, GtkWidget *button) { - const gchar *id; + const char *id; gboolean has_selection; id = gtk_buildable_get_name (GTK_BUILDABLE (button)); @@ -1469,7 +1469,7 @@ page_combo_separator_func (GtkTreeModel *model, GtkTreeIter *iter, gpointer data) { - gchar *text; + char *text; gboolean res; gtk_tree_model_get (model, iter, 0, &text, -1); @@ -1594,7 +1594,7 @@ text_view_add_to_context_menu (GtkTextView *text_view) static void open_popover_text_changed (GtkEntry *entry, GParamSpec *pspec, GtkWidget *button) { - const gchar *text; + const char *text; text = gtk_editable_get_text (GTK_EDITABLE (entry)); gtk_widget_set_sensitive (button, strlen (text) > 0); @@ -1864,8 +1864,8 @@ activate (GApplication *app) { "print", activate_print, NULL, NULL, NULL }, }; struct { - const gchar *action_and_target; - const gchar *accelerators[2]; + const char *action_and_target; + const char *accelerators[2]; } accels[] = { { "app.about", { "F1", NULL } }, { "app.quit", { "<Control>q", NULL } }, @@ -1878,8 +1878,8 @@ activate (GApplication *app) { "win.lock", { "<Control>l", NULL } }, }; struct { - const gchar *action_and_target; - const gchar *accelerators[2]; + const char *action_and_target; + const char *accelerators[2]; } late_accels[] = { { "app.cut", { "<Control>x", NULL } }, { "app.copy", { "<Control>c", NULL } }, |