Callisto Desktop for trixie
This commit is contained in:
parent
305d14d69f
commit
9219219e29
8
debian/changelog
vendored
8
debian/changelog
vendored
@ -1,3 +1,11 @@
|
|||||||
|
gtk+3.0 (3.24.49-3.1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* Callisto Desktop for trixie
|
||||||
|
- Patch 3001 regenerated from bookworm to address fuzz/offset
|
||||||
|
- Patch 3004 reworked from bookworm to accommodate upstream changes
|
||||||
|
|
||||||
|
-- Maia <maia@tsundoku.ne.jp> Thu, 08 May 2025 17:09:02 -0700
|
||||||
|
|
||||||
gtk+3.0 (3.24.49-3) unstable; urgency=medium
|
gtk+3.0 (3.24.49-3) unstable; urgency=medium
|
||||||
|
|
||||||
* Cherry-pick fixes from gtk-3-24 branch including
|
* Cherry-pick fixes from gtk-3-24 branch including
|
||||||
|
1501
debian/patches/gtk3_3000-ja-no-mnemonics.patch
vendored
Normal file
1501
debian/patches/gtk3_3000-ja-no-mnemonics.patch
vendored
Normal file
File diff suppressed because it is too large
Load Diff
195
debian/patches/gtk3_3001-primary-accelerator-command.patch
vendored
Normal file
195
debian/patches/gtk3_3001-primary-accelerator-command.patch
vendored
Normal file
@ -0,0 +1,195 @@
|
|||||||
|
Description: Change primary accelerator from Control to Command (Super)
|
||||||
|
Origin: Callisto Desktop
|
||||||
|
Author: maia <maia@tsundoku.ne.jp>
|
||||||
|
Last-Update: 2025-05-07
|
||||||
|
diff -urN a/gdk/gdkkeys.c b/gdk/gdkkeys.c
|
||||||
|
--- a/gdk/gdkkeys.c 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gdk/gdkkeys.c 2025-05-07 17:03:20.831877512 -0700
|
||||||
|
@@ -638,7 +638,7 @@
|
||||||
|
switch (intent)
|
||||||
|
{
|
||||||
|
case GDK_MODIFIER_INTENT_PRIMARY_ACCELERATOR:
|
||||||
|
- return GDK_CONTROL_MASK;
|
||||||
|
+ return GDK_SUPER_MASK;
|
||||||
|
|
||||||
|
case GDK_MODIFIER_INTENT_CONTEXT_MENU:
|
||||||
|
return 0;
|
||||||
|
@@ -647,10 +647,10 @@
|
||||||
|
return GDK_SHIFT_MASK;
|
||||||
|
|
||||||
|
case GDK_MODIFIER_INTENT_MODIFY_SELECTION:
|
||||||
|
- return GDK_CONTROL_MASK;
|
||||||
|
+ return GDK_SUPER_MASK;
|
||||||
|
|
||||||
|
case GDK_MODIFIER_INTENT_NO_TEXT_INPUT:
|
||||||
|
- return GDK_MOD1_MASK | GDK_CONTROL_MASK;
|
||||||
|
+ return GDK_MOD1_MASK | GDK_SUPER_MASK | GDK_CONTROL_MASK;
|
||||||
|
|
||||||
|
case GDK_MODIFIER_INTENT_SHIFT_GROUP:
|
||||||
|
return 0;
|
||||||
|
diff -urN a/gtk/deprecated/gtkstock.c b/gtk/deprecated/gtkstock.c
|
||||||
|
--- a/gtk/deprecated/gtkstock.c 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gtk/deprecated/gtkstock.c 2025-05-07 17:03:20.831877512 -0700
|
||||||
|
@@ -104,7 +104,7 @@
|
||||||
|
{
|
||||||
|
item = gtk_stock_item_copy (item);
|
||||||
|
((GtkStockItem *)item)->modifier = (NON_STATIC_MASK |
|
||||||
|
- _gtk_get_primary_accel_mod ());
|
||||||
|
+ GDK_SUPER_MASK);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
diff -urN a/gtk/gtkentry.c b/gtk/gtkentry.c
|
||||||
|
--- a/gtk/gtkentry.c 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gtk/gtkentry.c 2025-05-07 17:03:20.835877555 -0700
|
||||||
|
@@ -1963,16 +1963,16 @@
|
||||||
|
add_move_binding (binding_set, GDK_KEY_KP_Left, 0,
|
||||||
|
GTK_MOVEMENT_VISUAL_POSITIONS, -1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_Right, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_Right, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_WORDS, 1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_Left, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_Left, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_WORDS, -1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_KP_Right, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_KP_Right, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_WORDS, 1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_KP_Left, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_KP_Left, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_WORDS, -1);
|
||||||
|
|
||||||
|
add_move_binding (binding_set, GDK_KEY_Home, 0,
|
||||||
|
@@ -1987,49 +1987,49 @@
|
||||||
|
add_move_binding (binding_set, GDK_KEY_KP_End, 0,
|
||||||
|
GTK_MOVEMENT_DISPLAY_LINE_ENDS, 1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_Home, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_Home, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_BUFFER_ENDS, -1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_End, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_End, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_BUFFER_ENDS, 1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_KP_Home, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_KP_Home, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_BUFFER_ENDS, -1);
|
||||||
|
|
||||||
|
- add_move_binding (binding_set, GDK_KEY_KP_End, GDK_CONTROL_MASK,
|
||||||
|
+ add_move_binding (binding_set, GDK_KEY_KP_End, GDK_SUPER_MASK,
|
||||||
|
GTK_MOVEMENT_BUFFER_ENDS, 1);
|
||||||
|
|
||||||
|
/* Select all
|
||||||
|
*/
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_BUFFER_ENDS,
|
||||||
|
G_TYPE_INT, -1,
|
||||||
|
G_TYPE_BOOLEAN, FALSE);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_BUFFER_ENDS,
|
||||||
|
G_TYPE_INT, 1,
|
||||||
|
G_TYPE_BOOLEAN, TRUE);
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_slash, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_slash, GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_BUFFER_ENDS,
|
||||||
|
G_TYPE_INT, -1,
|
||||||
|
G_TYPE_BOOLEAN, FALSE);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_slash, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_slash, GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_BUFFER_ENDS,
|
||||||
|
G_TYPE_INT, 1,
|
||||||
|
G_TYPE_BOOLEAN, TRUE);
|
||||||
|
/* Unselect all
|
||||||
|
*/
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_backslash, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_backslash, GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_VISUAL_POSITIONS,
|
||||||
|
G_TYPE_INT, 0,
|
||||||
|
G_TYPE_BOOLEAN, FALSE);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_SHIFT_MASK | GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_a, GDK_SHIFT_MASK | GDK_SUPER_MASK,
|
||||||
|
"move-cursor", 3,
|
||||||
|
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_VISUAL_POSITIONS,
|
||||||
|
G_TYPE_INT, 0,
|
||||||
|
@@ -2058,7 +2058,7 @@
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_BackSpace, 0,
|
||||||
|
"backspace", 0);
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_u, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_u, GDK_SUPER_MASK,
|
||||||
|
"delete-from-cursor", 2,
|
||||||
|
G_TYPE_ENUM, GTK_DELETE_PARAGRAPH_ENDS,
|
||||||
|
G_TYPE_INT, -1);
|
||||||
|
@@ -2067,40 +2067,40 @@
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_BackSpace, GDK_SHIFT_MASK,
|
||||||
|
"backspace", 0);
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_Delete, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_Delete, GDK_SUPER_MASK,
|
||||||
|
"delete-from-cursor", 2,
|
||||||
|
G_TYPE_ENUM, GTK_DELETE_WORD_ENDS,
|
||||||
|
G_TYPE_INT, 1);
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Delete, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Delete, GDK_SUPER_MASK,
|
||||||
|
"delete-from-cursor", 2,
|
||||||
|
G_TYPE_ENUM, GTK_DELETE_WORD_ENDS,
|
||||||
|
G_TYPE_INT, 1);
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_BackSpace, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_BackSpace, GDK_SUPER_MASK,
|
||||||
|
"delete-from-cursor", 2,
|
||||||
|
G_TYPE_ENUM, GTK_DELETE_WORD_ENDS,
|
||||||
|
G_TYPE_INT, -1);
|
||||||
|
|
||||||
|
/* Cut/copy/paste */
|
||||||
|
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_x, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_x, GDK_SUPER_MASK,
|
||||||
|
"cut-clipboard", 0);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_c, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_c, GDK_SUPER_MASK,
|
||||||
|
"copy-clipboard", 0);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_v, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_v, GDK_SUPER_MASK,
|
||||||
|
"paste-clipboard", 0);
|
||||||
|
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_Delete, GDK_SHIFT_MASK,
|
||||||
|
"cut-clipboard", 0);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_Insert, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_Insert, GDK_SUPER_MASK,
|
||||||
|
"copy-clipboard", 0);
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_Insert, GDK_SHIFT_MASK,
|
||||||
|
"paste-clipboard", 0);
|
||||||
|
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Delete, GDK_SHIFT_MASK,
|
||||||
|
"cut-clipboard", 0);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Insert, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Insert, GDK_SUPER_MASK,
|
||||||
|
"copy-clipboard", 0);
|
||||||
|
gtk_binding_entry_add_signal (binding_set, GDK_KEY_KP_Insert, GDK_SHIFT_MASK,
|
||||||
|
"paste-clipboard", 0);
|
||||||
|
@@ -2132,9 +2132,9 @@
|
||||||
|
GTK_PARAM_READABLE |
|
||||||
|
G_PARAM_DEPRECATED));
|
||||||
|
/* Emoji */
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_period, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_period, GDK_SUPER_MASK,
|
||||||
|
"insert-emoji", 0);
|
||||||
|
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_semicolon, GDK_CONTROL_MASK,
|
||||||
|
+ gtk_binding_entry_add_signal (binding_set, GDK_KEY_semicolon, GDK_SUPER_MASK,
|
||||||
|
"insert-emoji", 0);
|
||||||
|
|
||||||
|
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_ENTRY_ACCESSIBLE);
|
92
debian/patches/gtk3_3002-symbolic-accellabel.patch
vendored
Normal file
92
debian/patches/gtk3_3002-symbolic-accellabel.patch
vendored
Normal file
@ -0,0 +1,92 @@
|
|||||||
|
Description: Use symbolic accelerator labels in menus
|
||||||
|
Upstream GTK has Mac-style accelerator symbols defined for use
|
||||||
|
only when GTK is being compiled in macOS. We want them too
|
||||||
|
(with minor adjustments), so we remove the Windows-style labels
|
||||||
|
("Ctrl+" "Shift+" etc.) and the conditional preprocessor directives.
|
||||||
|
Origin: Callisto Desktop
|
||||||
|
Author: Maia <maia@tsundoku.ne.jp>
|
||||||
|
Last-Update: 2019-02-23
|
||||||
|
--- a/gtk/gtkaccellabel.c
|
||||||
|
+++ b/gtk/gtkaccellabel.c
|
||||||
|
@@ -172,28 +172,6 @@
|
||||||
|
class->signal_quote1 = g_strdup ("<:");
|
||||||
|
class->signal_quote2 = g_strdup (":>");
|
||||||
|
|
||||||
|
-#ifndef GDK_WINDOWING_QUARTZ
|
||||||
|
- /* This is the text that should appear next to menu accelerators
|
||||||
|
- * that use the shift key. If the text on this key isn't typically
|
||||||
|
- * translated on keyboards used for your language, don't translate
|
||||||
|
- * this.
|
||||||
|
- */
|
||||||
|
- class->mod_name_shift = g_strdup (C_("keyboard label", "Shift"));
|
||||||
|
- /* This is the text that should appear next to menu accelerators
|
||||||
|
- * that use the control key. If the text on this key isn't typically
|
||||||
|
- * translated on keyboards used for your language, don't translate
|
||||||
|
- * this.
|
||||||
|
- */
|
||||||
|
- class->mod_name_control = g_strdup (C_("keyboard label", "Ctrl"));
|
||||||
|
- /* This is the text that should appear next to menu accelerators
|
||||||
|
- * that use the alt key. If the text on this key isn't typically
|
||||||
|
- * translated on keyboards used for your language, don't translate
|
||||||
|
- * this.
|
||||||
|
- */
|
||||||
|
- class->mod_name_alt = g_strdup (C_("keyboard label", "Alt"));
|
||||||
|
- class->mod_separator = g_strdup ("+");
|
||||||
|
-#else /* GDK_WINDOWING_QUARTZ */
|
||||||
|
-
|
||||||
|
/* U+21E7 UPWARDS WHITE ARROW */
|
||||||
|
class->mod_name_shift = g_strdup ("\xe2\x87\xa7");
|
||||||
|
/* U+2303 UP ARROWHEAD */
|
||||||
|
@@ -202,8 +180,6 @@
|
||||||
|
class->mod_name_alt = g_strdup ("\xe2\x8c\xa5");
|
||||||
|
class->mod_separator = g_strdup ("");
|
||||||
|
|
||||||
|
-#endif /* GDK_WINDOWING_QUARTZ */
|
||||||
|
-
|
||||||
|
props[PROP_ACCEL_CLOSURE] =
|
||||||
|
g_param_spec_boxed ("accel-closure",
|
||||||
|
P_("Accelerator Closure"),
|
||||||
|
@@ -694,12 +670,11 @@
|
||||||
|
append_keyval_symbol (guint accelerator_key,
|
||||||
|
GString *gstring)
|
||||||
|
{
|
||||||
|
-#ifdef GDK_WINDOWING_QUARTZ
|
||||||
|
switch (accelerator_key)
|
||||||
|
{
|
||||||
|
case GDK_KEY_Return:
|
||||||
|
- /* U+21A9 LEFTWARDS ARROW WITH HOOK */
|
||||||
|
- g_string_append (gstring, "\xe2\x86\xa9");
|
||||||
|
+ /* U+21B5 DOWN ARROW WITH CORNER LEFT (CARRIAGE RETURN) */
|
||||||
|
+ g_string_append (gstring, "\xe2\x86\xb5");
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
|
case GDK_KEY_ISO_Enter:
|
||||||
|
@@ -765,9 +740,6 @@
|
||||||
|
default:
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
-#else /* !GDK_WINDOWING_QUARTZ */
|
||||||
|
- return FALSE;
|
||||||
|
-#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
gchar *
|
||||||
|
@@ -842,7 +814,7 @@
|
||||||
|
* translated on keyboards used for your language, don't translate
|
||||||
|
* this.
|
||||||
|
*/
|
||||||
|
- g_string_append (gstring, C_("keyboard label", "Super"));
|
||||||
|
+ g_string_append (gstring, C_("keyboard label", "\xe2\x8c\x98"));
|
||||||
|
seen_mod = TRUE;
|
||||||
|
}
|
||||||
|
if (accelerator_mods & GDK_HYPER_MASK)
|
||||||
|
@@ -869,7 +841,8 @@
|
||||||
|
* translated on keyboards used for your language, don't translate
|
||||||
|
* this.
|
||||||
|
*/
|
||||||
|
- g_string_append (gstring, C_("keyboard label", "Meta"));
|
||||||
|
+ /* Meta key symbol U+2B26 WHITE MEDIUM DIAMOND */
|
||||||
|
+ g_string_append (gstring, "\xe2\xac\xa6");
|
||||||
|
#else
|
||||||
|
/* Command key symbol U+2318 PLACE OF INTEREST SIGN */
|
||||||
|
g_string_append (gstring, "\xe2\x8c\x98");
|
19
debian/patches/gtk3_3003-toolbar-icons-16px.patch
vendored
Normal file
19
debian/patches/gtk3_3003-toolbar-icons-16px.patch
vendored
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
Description: Force 16x16 toolbar icons
|
||||||
|
Specifying a systemwide toolbar icon size is no longer available
|
||||||
|
to GTK themes, so we set it here instead.
|
||||||
|
Origin: Callisto Desktop
|
||||||
|
Author: Maia <maia@tsundoku.ne.jp>
|
||||||
|
Last-Update: 2019-02-23
|
||||||
|
--- a/gtk/deprecated/gtkiconfactory.c
|
||||||
|
+++ b/gtk/deprecated/gtkiconfactory.c
|
||||||
|
@@ -689,8 +689,8 @@
|
||||||
|
|
||||||
|
icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].size = GTK_ICON_SIZE_LARGE_TOOLBAR;
|
||||||
|
icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].name = "gtk-large-toolbar";
|
||||||
|
- icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].width = 24;
|
||||||
|
- icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].height = 24;
|
||||||
|
+ icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].width = 16;
|
||||||
|
+ icon_sizes[GTK_ICON_SIZE_LARGE_TOOLBAR].height = 16;
|
||||||
|
|
||||||
|
icon_sizes[GTK_ICON_SIZE_DND].size = GTK_ICON_SIZE_DND;
|
||||||
|
icon_sizes[GTK_ICON_SIZE_DND].name = "gtk-dnd";
|
281
debian/patches/gtk3_3004-gtkmessagedialog-style.patch
vendored
Normal file
281
debian/patches/gtk3_3004-gtkmessagedialog-style.patch
vendored
Normal file
@ -0,0 +1,281 @@
|
|||||||
|
diff -urN a/gtk/gtkmessagedialog.c b/gtk/gtkmessagedialog.c
|
||||||
|
--- a/gtk/gtkmessagedialog.c 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gtk/gtkmessagedialog.c 2025-05-08 17:34:23.077661286 -0700
|
||||||
|
@@ -44,7 +44,8 @@
|
||||||
|
* @Title: GtkMessageDialog
|
||||||
|
* @See_also:#GtkDialog
|
||||||
|
*
|
||||||
|
- * #GtkMessageDialog presents a dialog with some message text. It’s simply a
|
||||||
|
+ * #GtkMessageDialog presents a dialog with an image representing the type of
|
||||||
|
+ * message (Error, Question, etc.) alongside some message text. It’s simply a
|
||||||
|
* convenience widget; you could construct the equivalent of #GtkMessageDialog
|
||||||
|
* from #GtkDialog without too much effort, but #GtkMessageDialog saves typing.
|
||||||
|
*
|
||||||
|
@@ -171,8 +172,8 @@
|
||||||
|
|
||||||
|
gtk_widget_class_install_style_property (widget_class,
|
||||||
|
g_param_spec_int ("message-border",
|
||||||
|
- P_("label border"),
|
||||||
|
- P_("Width of border around the label in the message dialog"),
|
||||||
|
+ P_("Image/label border"),
|
||||||
|
+ P_("Width of border around the label and image in the message dialog"),
|
||||||
|
0,
|
||||||
|
G_MAXINT,
|
||||||
|
12,
|
||||||
|
@@ -181,7 +182,9 @@
|
||||||
|
/**
|
||||||
|
* GtkMessageDialog:message-type:
|
||||||
|
*
|
||||||
|
- * The type of the message.
|
||||||
|
+ * The type of the message. The type is used to determine
|
||||||
|
+ * the image that is shown in the dialog, unless the image i
|
||||||
|
+ * explicitly set by the ::image property.
|
||||||
|
*/
|
||||||
|
g_object_class_install_property (gobject_class,
|
||||||
|
PROP_MESSAGE_TYPE,
|
||||||
|
@@ -269,7 +272,6 @@
|
||||||
|
* The image for this dialog.
|
||||||
|
*
|
||||||
|
* Since: 2.10
|
||||||
|
- * Deprecated: 3.12: Use #GtkDialog to create dialogs with images
|
||||||
|
*/
|
||||||
|
g_object_class_install_property (gobject_class,
|
||||||
|
PROP_IMAGE,
|
||||||
|
@@ -277,7 +279,7 @@
|
||||||
|
P_("Image"),
|
||||||
|
P_("The image"),
|
||||||
|
GTK_TYPE_WIDGET,
|
||||||
|
- GTK_PARAM_READWRITE|G_PARAM_DEPRECATED));
|
||||||
|
+ GTK_PARAM_READWRITE));
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GtkMessageDialog:message-area:
|
||||||
|
@@ -298,6 +300,7 @@
|
||||||
|
|
||||||
|
/* Setup Composite data */
|
||||||
|
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/ui/gtkmessagedialog.ui");
|
||||||
|
+ gtk_widget_class_bind_template_child_private (widget_class, GtkMessageDialog, image);
|
||||||
|
gtk_widget_class_bind_template_child_private (widget_class, GtkMessageDialog, label);
|
||||||
|
gtk_widget_class_bind_template_child_private (widget_class, GtkMessageDialog, secondary_label);
|
||||||
|
gtk_widget_class_bind_template_child_internal_private (widget_class, GtkMessageDialog, message_area);
|
||||||
|
@@ -327,7 +330,7 @@
|
||||||
|
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||||
|
action_area = gtk_dialog_get_action_area (GTK_DIALOG (dialog));
|
||||||
|
G_GNUC_END_IGNORE_DEPRECATIONS
|
||||||
|
- gtk_button_box_set_layout (GTK_BUTTON_BOX (action_area), GTK_BUTTONBOX_EXPAND);
|
||||||
|
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (action_area), GTK_BUTTONBOX_END);
|
||||||
|
|
||||||
|
settings = gtk_widget_get_settings (GTK_WIDGET (dialog));
|
||||||
|
g_object_get (settings, "gtk-keynav-use-caret", &use_caret, NULL);
|
||||||
|
@@ -416,12 +419,42 @@
|
||||||
|
{
|
||||||
|
GtkMessageDialogPrivate *priv = dialog->priv;
|
||||||
|
AtkObject *atk_obj;
|
||||||
|
+ GIcon *gicon = NULL;
|
||||||
|
|
||||||
|
if (priv->message_type == type)
|
||||||
|
return;
|
||||||
|
|
||||||
|
priv->message_type = type;
|
||||||
|
|
||||||
|
+ switch (type)
|
||||||
|
+ {
|
||||||
|
+ case GTK_MESSAGE_INFO:
|
||||||
|
+ gicon = g_themed_icon_new_with_default_fallbacks ("dialog-information-symbolic");
|
||||||
|
+ break;
|
||||||
|
+
|
||||||
|
+ case GTK_MESSAGE_QUESTION:
|
||||||
|
+ gicon = g_themed_icon_new_with_default_fallbacks ("dialog-question-symbolic");
|
||||||
|
+ break;
|
||||||
|
+
|
||||||
|
+ case GTK_MESSAGE_WARNING:
|
||||||
|
+ gicon = g_themed_icon_new_with_default_fallbacks ("dialog-warning-symbolic");
|
||||||
|
+ break;
|
||||||
|
+
|
||||||
|
+ case GTK_MESSAGE_ERROR:
|
||||||
|
+ gicon = g_themed_icon_new_with_default_fallbacks ("dialog-error-symbolic");
|
||||||
|
+ break;
|
||||||
|
+
|
||||||
|
+ case GTK_MESSAGE_OTHER:
|
||||||
|
+ break;
|
||||||
|
+
|
||||||
|
+ default:
|
||||||
|
+ g_warning ("Unknown GtkMessageType %u", type);
|
||||||
|
+ break;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ gtk_image_set_from_gicon (GTK_IMAGE (priv->image), gicon, GTK_ICON_SIZE_DIALOG);
|
||||||
|
+ if (gicon)
|
||||||
|
+ g_object_unref (gicon);
|
||||||
|
|
||||||
|
atk_obj = gtk_widget_get_accessible (GTK_WIDGET (dialog));
|
||||||
|
if (GTK_IS_ACCESSIBLE (atk_obj))
|
||||||
|
@@ -543,9 +576,7 @@
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case PROP_IMAGE:
|
||||||
|
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||||
|
gtk_message_dialog_set_image (dialog, g_value_get_object (value));
|
||||||
|
-G_GNUC_END_IGNORE_DEPRECATIONS
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
@@ -738,7 +769,6 @@
|
||||||
|
* Sets the dialog’s image to @image.
|
||||||
|
*
|
||||||
|
* Since: 2.10
|
||||||
|
- * Deprecated: 3.12: Use #GtkDialog to create dialogs with images
|
||||||
|
**/
|
||||||
|
void
|
||||||
|
gtk_message_dialog_set_image (GtkMessageDialog *dialog,
|
||||||
|
@@ -752,22 +782,22 @@
|
||||||
|
|
||||||
|
priv = dialog->priv;
|
||||||
|
|
||||||
|
- if (priv->image)
|
||||||
|
- gtk_widget_destroy (priv->image);
|
||||||
|
-
|
||||||
|
- priv->image = image;
|
||||||
|
-
|
||||||
|
- if (priv->image)
|
||||||
|
- {
|
||||||
|
- gtk_widget_set_halign (priv->image, GTK_ALIGN_CENTER);
|
||||||
|
- gtk_widget_set_valign (priv->image, GTK_ALIGN_START);
|
||||||
|
- parent = gtk_widget_get_parent (priv->message_area);
|
||||||
|
- gtk_container_add (GTK_CONTAINER (parent), priv->image);
|
||||||
|
- gtk_box_reorder_child (GTK_BOX (parent), priv->image, 0);
|
||||||
|
+ if (image == NULL)
|
||||||
|
+ {
|
||||||
|
+ image = gtk_image_new_from_icon_name (NULL, GTK_ICON_SIZE_DIALOG);
|
||||||
|
+ gtk_widget_set_halign (image, GTK_ALIGN_CENTER);
|
||||||
|
+ gtk_widget_set_valign (image, GTK_ALIGN_START);
|
||||||
|
}
|
||||||
|
-
|
||||||
|
+
|
||||||
|
priv->message_type = GTK_MESSAGE_OTHER;
|
||||||
|
|
||||||
|
+ parent = gtk_widget_get_parent (priv->image);
|
||||||
|
+ gtk_container_add (GTK_CONTAINER (parent), image);
|
||||||
|
+ gtk_container_remove (GTK_CONTAINER (parent), priv->image);
|
||||||
|
+ gtk_box_reorder_child (GTK_BOX (parent), image, 0);
|
||||||
|
+
|
||||||
|
+ priv->image = image;
|
||||||
|
+
|
||||||
|
g_object_notify (G_OBJECT (dialog), "image");
|
||||||
|
g_object_notify (G_OBJECT (dialog), "message-type");
|
||||||
|
}
|
||||||
|
@@ -781,7 +811,6 @@
|
||||||
|
* Returns: (transfer none): the dialog’s image
|
||||||
|
*
|
||||||
|
* Since: 2.14
|
||||||
|
- * Deprecated: 3.12: Use #GtkDialog for dialogs with images
|
||||||
|
**/
|
||||||
|
GtkWidget *
|
||||||
|
gtk_message_dialog_get_image (GtkMessageDialog *dialog)
|
||||||
|
@@ -929,8 +958,9 @@
|
||||||
|
*
|
||||||
|
* Returns the message area of the dialog. This is the box where the
|
||||||
|
* dialog’s primary and secondary labels are packed. You can add your
|
||||||
|
- * own extra content to that box and it will appear below those labels.
|
||||||
|
- * See gtk_dialog_get_content_area() for the corresponding
|
||||||
|
+ * own extra content to that box and it will appear below those labels,
|
||||||
|
+ * on the right side of the dialog’s image (or on the left for right-to-left
|
||||||
|
+ * languages). See gtk_dialog_get_content_area() for the corresponding
|
||||||
|
* function in the parent #GtkDialog.
|
||||||
|
*
|
||||||
|
* Returns: (transfer none): A #GtkBox corresponding to the
|
||||||
|
@@ -1005,7 +1035,7 @@
|
||||||
|
GtkWidget *parent;
|
||||||
|
gint border_width;
|
||||||
|
|
||||||
|
- parent = gtk_widget_get_parent (dialog->priv->message_area);
|
||||||
|
+ parent = gtk_widget_get_parent (gtk_message_dialog_get_image (dialog));
|
||||||
|
|
||||||
|
if (parent)
|
||||||
|
{
|
||||||
|
diff -urN a/gtk/gtkmessagedialog.h b/gtk/gtkmessagedialog.h
|
||||||
|
--- a/gtk/gtkmessagedialog.h 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gtk/gtkmessagedialog.h 2025-05-08 17:26:20.477242282 -0700
|
||||||
|
@@ -111,11 +111,11 @@
|
||||||
|
const gchar *message_format,
|
||||||
|
...) G_GNUC_PRINTF (5, 6);
|
||||||
|
|
||||||
|
-GDK_DEPRECATED_IN_3_12
|
||||||
|
+GDK_AVAILABLE_IN_ALL
|
||||||
|
void gtk_message_dialog_set_image (GtkMessageDialog *dialog,
|
||||||
|
GtkWidget *image);
|
||||||
|
|
||||||
|
-GDK_DEPRECATED_IN_3_12
|
||||||
|
+GDK_AVAILABLE_IN_ALL
|
||||||
|
GtkWidget * gtk_message_dialog_get_image (GtkMessageDialog *dialog);
|
||||||
|
|
||||||
|
GDK_AVAILABLE_IN_ALL
|
||||||
|
diff -urN a/gtk/ui/gtkmessagedialog.ui b/gtk/ui/gtkmessagedialog.ui
|
||||||
|
--- a/gtk/ui/gtkmessagedialog.ui 2025-03-05 15:31:26.000000000 -0800
|
||||||
|
+++ b/gtk/ui/gtkmessagedialog.ui 2025-05-08 17:26:20.477242282 -0700
|
||||||
|
@@ -2,6 +2,7 @@
|
||||||
|
<interface domain="gtk30">
|
||||||
|
<!-- interface-requires gtk+ 3.10 -->
|
||||||
|
<template class="GtkMessageDialog" parent="GtkDialog">
|
||||||
|
+ <property name="border_width">5</property>
|
||||||
|
<property name="title"></property>
|
||||||
|
<property name="resizable">0</property>
|
||||||
|
<property name="type-hint">dialog</property>
|
||||||
|
@@ -14,24 +15,39 @@
|
||||||
|
<child internal-child="vbox">
|
||||||
|
<object class="GtkBox" id="dialog-vbox1">
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
- <property name="spacing">20</property>
|
||||||
|
+ <property name="spacing">14</property>
|
||||||
|
<property name="border-width">0</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox" id="box">
|
||||||
|
<property name="visible">1</property>
|
||||||
|
- <property name="margin-start">30</property>
|
||||||
|
- <property name="margin-end">30</property>
|
||||||
|
- <property name="spacing">30</property>
|
||||||
|
+ <property name="border_width">5</property>
|
||||||
|
+ <property name="spacing">12</property>
|
||||||
|
+ <child>
|
||||||
|
+ <object class="GtkImage" id="image">
|
||||||
|
+ <property name="visible">1</property>
|
||||||
|
+ <property name="halign">center</property>
|
||||||
|
+ <property name="valign">start</property>
|
||||||
|
+ <property name="stock">gtk-missing-image</property>
|
||||||
|
+ <property name="use_fallback">True</property>
|
||||||
|
+ <property name="icon_size">6</property>
|
||||||
|
+ <property name="xpad">6</property>
|
||||||
|
+ </object>
|
||||||
|
+ <packing>
|
||||||
|
+ <property name="expand">False</property>
|
||||||
|
+ <property name="fill">False</property>
|
||||||
|
+ <property name="position">0</property>
|
||||||
|
+ </packing>
|
||||||
|
+ </child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox" id="message_area">
|
||||||
|
<property name="visible">1</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
- <property name="spacing">10</property>
|
||||||
|
+ <property name="spacing">12</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkLabel" id="label">
|
||||||
|
<property name="visible">1</property>
|
||||||
|
- <property name="halign">center</property>
|
||||||
|
- <property name="valign">start</property>
|
||||||
|
+ <property name="halign">start</property>
|
||||||
|
+ <property name="valign">center</property>
|
||||||
|
<property name="wrap">1</property>
|
||||||
|
<property name="max-width-chars">60</property>
|
||||||
|
</object>
|
||||||
|
@@ -43,8 +59,8 @@
|
||||||
|
<object class="GtkLabel" id="secondary_label">
|
||||||
|
<property name="no-show-all">1</property>
|
||||||
|
<property name="margin-bottom">2</property>
|
||||||
|
- <property name="halign">center</property>
|
||||||
|
- <property name="valign">start</property>
|
||||||
|
+ <property name="halign">start</property>
|
||||||
|
+ <property name="valign">center</property>
|
||||||
|
<property name="wrap">1</property>
|
||||||
|
<property name="max-width-chars">60</property>
|
||||||
|
</object>
|
5
debian/patches/series
vendored
5
debian/patches/series
vendored
@ -10,3 +10,8 @@ widget-Explicitly-annotate-sensitive-s-getter.patch
|
|||||||
action-Annotate-sensitive-visible-getters.patch
|
action-Annotate-sensitive-visible-getters.patch
|
||||||
widget-Fix-typo-in-docstring-s-property-name.patch
|
widget-Fix-typo-in-docstring-s-property-name.patch
|
||||||
icons-add-spinner-icon.patch
|
icons-add-spinner-icon.patch
|
||||||
|
gtk3_3000-ja-no-mnemonics.patch
|
||||||
|
gtk3_3001-primary-accelerator-command.patch
|
||||||
|
gtk3_3002-symbolic-accellabel.patch
|
||||||
|
gtk3_3003-toolbar-icons-16px.patch
|
||||||
|
gtk3_3004-gtkmessagedialog-style.patch
|
||||||
|
Loading…
Reference in New Issue
Block a user