diff -Nru mousepad-0.4.0/debian/changelog mousepad-0.4.0/debian/changelog --- mousepad-0.4.0/debian/changelog 2015-11-10 12:51:25.000000000 +0000 +++ mousepad-0.4.0/debian/changelog 2016-06-30 13:09:19.000000000 +0000 @@ -1,3 +1,25 @@ +mousepad (0.4.0-4ubuntu1) devel; urgency=medium + + * Merge from Debian unstable. Remaining changes: + - debian/control, debian/rules: + + Switch to gtk3. + - git-width-mismatch.patch: stop a tab width related crash. LP: #1472690 + * d/p/git-width-mismatch.patch: + - Update to patch the generated .h file rather than upstream glade file. + + -- Unit 193 Mon, 13 Jun 2016 05:45:59 +0000 + +mousepad (0.4.0-4) unstable; urgency=medium + + * debian/patches: + - 01_prevent-a-g_settings-cycle and + 02_do-not-manually-update-the-view-theme added, fix bug leading to huge + DBus trafic and large CPU usage. closes: #795192 + * debian/control: + - update standards version to 3.9.8. + + -- Yves-Alexis Perez Sun, 12 Jun 2016 21:59:50 +0200 + mousepad (0.4.0-3ubuntu1) xenial; urgency=medium * Merge from Debian unstable. Remaining changes: diff -Nru mousepad-0.4.0/debian/control mousepad-0.4.0/debian/control --- mousepad-0.4.0/debian/control 2015-05-27 20:48:00.000000000 +0000 +++ mousepad-0.4.0/debian/control 2016-06-30 12:57:00.000000000 +0000 @@ -7,7 +7,7 @@ Yves-Alexis Perez Build-Depends: debhelper (>= 9), pkg-config, libxml-parser-perl, intltool, libgtksourceview-3.0-dev, libglib2.0-dev, xfce4-dev-tools, dh-autoreconf -Standards-Version: 3.9.6 +Standards-Version: 3.9.8 Vcs-Svn: svn://anonscm.debian.org/pkg-xfce/desktop/trunk/mousepad/ Vcs-Browser: http://anonscm.debian.org/viewvc/pkg-xfce/desktop/trunk/mousepad/ diff -Nru mousepad-0.4.0/debian/patches/01_prevent-a-g_settings-cycle.patch mousepad-0.4.0/debian/patches/01_prevent-a-g_settings-cycle.patch --- mousepad-0.4.0/debian/patches/01_prevent-a-g_settings-cycle.patch 1970-01-01 00:00:00.000000000 +0000 +++ mousepad-0.4.0/debian/patches/01_prevent-a-g_settings-cycle.patch 2016-06-12 17:06:05.000000000 +0000 @@ -0,0 +1,53 @@ +From 320deb1ec28ddb5e9647b154f2c08f358ba2c4cb Mon Sep 17 00:00:00 2001 +From: Alistair Buxton +Date: Mon, 21 Mar 2016 23:34:12 +0000 +Subject: [PATCH 2/3] Prevent a g_settings cycle. + +When the selected menu item changes, only update the g_setting. +When the g_setting changes, only update the selected menu item. + +This prevents g_setting changes from bouncing between windows +endlessly. +--- + mousepad/mousepad-action-group.c | 21 ++++++++++----------- + 1 file changed, 10 insertions(+), 11 deletions(-) + +--- a/mousepad/mousepad-action-group.c ++++ b/mousepad/mousepad-action-group.c +@@ -302,11 +302,6 @@ mousepad_action_group_set_active_style_s + gtk_toggle_action_set_active (GTK_TOGGLE_ACTION (action), TRUE); + self->locked = FALSE; + +- /* update the setting when the active action is changed */ +- self->locked = TRUE; +- MOUSEPAD_SETTING_SET_STRING (COLOR_SCHEME, gtk_source_style_scheme_get_id (scheme)); +- self->locked = FALSE; +- + g_object_notify (G_OBJECT (self), "active-style-scheme"); + } + +@@ -473,6 +468,8 @@ static void + mousepad_action_group_style_scheme_action_activate (MousepadActionGroup *self, + MousepadStyleSchemeAction *action) + { ++ const gchar *scheme_name = NULL; ++ + /* only update the active action if we're not already in the process of + * setting it and the sender action is actually active */ + if (! self->locked && +@@ -481,7 +478,14 @@ mousepad_action_group_style_scheme_actio + GtkSourceStyleScheme *scheme; + + scheme = mousepad_style_scheme_action_get_style_scheme (action); +- mousepad_action_group_set_active_style_scheme (self, scheme); ++ ++ /* update the setting when the active action is changed */ ++ if (scheme != NULL) ++ scheme_name = gtk_source_style_scheme_get_id(scheme); ++ ++ self->locked = TRUE; ++ MOUSEPAD_SETTING_SET_STRING (COLOR_SCHEME, scheme_name); ++ self->locked = FALSE; + } + } + diff -Nru mousepad-0.4.0/debian/patches/02_do-not-manually-update-the-view-theme.patch mousepad-0.4.0/debian/patches/02_do-not-manually-update-the-view-theme.patch --- mousepad-0.4.0/debian/patches/02_do-not-manually-update-the-view-theme.patch 1970-01-01 00:00:00.000000000 +0000 +++ mousepad-0.4.0/debian/patches/02_do-not-manually-update-the-view-theme.patch 2016-06-12 17:06:05.000000000 +0000 @@ -0,0 +1,58 @@ +From 376432b8061956d40e957fb64924e488e0837a1a Mon Sep 17 00:00:00 2001 +From: Alistair Buxton +Date: Mon, 21 Mar 2016 23:36:05 +0000 +Subject: [PATCH 3/3] Do not manually update the view theme. + +The view property is bound directly to the g_setting, so it will +be updated autoatically whenever that changes. The action group +updates the g_setting so we don't need to manually propagate the +setting. +--- + mousepad/mousepad-window.c | 34 ---------------------------------- + 1 file changed, 34 deletions(-) + +--- a/mousepad/mousepad-window.c ++++ b/mousepad/mousepad-window.c +@@ -711,29 +711,6 @@ mousepad_window_create_languages_menu (M + + + +-static void +-mousepad_window_action_group_style_scheme_changed (MousepadWindow *window, +- GParamSpec *pspec, +- MousepadActionGroup *group) +-{ +- GtkSourceStyleScheme *scheme; +- const gchar *scheme_id; +- gint npages, i; +- +- /* get the new active language */ +- scheme = mousepad_action_group_get_active_style_scheme (group); +- scheme_id = gtk_source_style_scheme_get_id (scheme); +- +- /* update the color scheme on all the documents */ +- npages = gtk_notebook_get_n_pages (GTK_NOTEBOOK (window->notebook)); +- for (i = 0; i < npages; i++) +- { +- MousepadDocument *document; +- +- document = MOUSEPAD_DOCUMENT (gtk_notebook_get_nth_page (GTK_NOTEBOOK (window->notebook), i)); +- mousepad_view_set_color_scheme (document->textview, scheme_id); +- } +-} + + + +@@ -752,12 +729,6 @@ mousepad_window_create_style_schemes_men + gtk_widget_show_all (menu); + gtk_widget_show (item); + +- /* watch for activations of the style schemes actions */ +- g_signal_connect_object (window->action_group, +- "notify::active-style-scheme", +- G_CALLBACK (mousepad_window_action_group_style_scheme_changed), +- window, +- G_CONNECT_SWAPPED); + } + + diff -Nru mousepad-0.4.0/debian/patches/git-width-mismatch.patch mousepad-0.4.0/debian/patches/git-width-mismatch.patch --- mousepad-0.4.0/debian/patches/git-width-mismatch.patch 2015-11-10 12:51:25.000000000 +0000 +++ mousepad-0.4.0/debian/patches/git-width-mismatch.patch 2016-06-30 13:06:28.000000000 +0000 @@ -1,23 +1,888 @@ -From 15f4e5a47bd85d2cd831f65d6a66e548ad4d5708 Mon Sep 17 00:00:00 2001 -From: Alistair Buxton -Date: Wed, 8 Jul 2015 17:18:30 +0100 -Subject: Limit prefs dialog tab width to range allowed by schema. +Description: Limit prefs dialog tab width to range allowed by schema. +Author: Unit 193 -Closes bug #12055 +Origin: upstream +Bug-Ubuntu: https://launchpad.net/bugs/1472690 -diff --git a/mousepad/mousepad-prefs-dialog.glade b/mousepad/mousepad-prefs-dialog.glade -index c886cb1..7bd8064 100644 ---- a/mousepad/mousepad-prefs-dialog.glade -+++ b/mousepad/mousepad-prefs-dialog.glade -@@ -43,7 +43,8 @@ - - - -- 128 -+ 1 -+ 32 - 8 - 1 - 10 --- -cgit v0.10.1 +--- mousepad-0.4.0.orig/mousepad/mousepad-prefs-dialog-ui.h ++++ mousepad-0.4.0/mousepad/mousepad-prefs-dialog-ui.h +@@ -21,448 +21,449 @@ static const char mousepad_prefs_dialog_ + "\"0\" translatable=\"yes\">Insert TabsInsert Spaces1288110noneNone9999110menuMenusmall-too" +- "lbarSmall Toolbar<" +- "row>large-toolbarLarge ToolbarbuttonButtondndDrag & DropdialogDialog" +- "iconsIcons Onlyte" +- "xtText OnlybothText Below Ico" +- "nsboth-horizText Beside IconsTrueTrueTrueFalse<" +- "property name=\"border_width\">6True<" +- "/property>False0noneTrueFalse66126TrueFalse2Show line numbersTrueTru" +- "eFalseTrueTru" +- "eTrueTrue0Display white" +- "spaceTrueTrueFals" +- "eTrue<" +- "packing>TrueTrue1Display line endingsTrueTrueFalseTrueTrueTrue2TrueFalse6" +- "Long line margin at column:TrueTrueFalseTru" +- "eFalseTrue0TrueFalseTrue\342\200\242" +- "TrueFalseFalseTrueTrue/prefs/view/right-margi" +- "n-adjustmentTrueFalseTrue1FalseTrue3Highlight current lineTrueTrueFalseTrueTrueTrueTrue4Highlight matching bracketsT" +- "rueTrueFalseTrueTrueTrue" +- "5Wrap long linesT" +- "rueTrueFalseTrueTrueTrue" +- "6TrueFalse<b" +- ">Display</b>TrueFals" +- "eTrue0TrueFalse0noneTrueFals" +- "e66126TrueFalse2Use system monospace fontTrue" +- "TrueFalseTr" +- "ueTrueTrue0True1328110" ++ "noneNone9999110" ++ "menuMenusmall-toolbarSmall Toolbarlarge-toolbarLarge ToolbarbuttonButton<" ++ "/row>dndDra" ++ "g & DropdialogDialog" ++ "iconsIcons " ++ "OnlytextText OnlybothText Below Iconsbo" ++ "th-horizText Beside IconsTrueTrueTrueFalse6TrueFalse0noneT" ++ "rueFalse66126TrueFalse2" ++ "Show line numbersTrueTrueTrueTrueTrue1TrueFalse<b>Font</b>True" +- "FalseTrue1" +- "TrueFalse0noneTrueFalse66126<" +- "child>FalseTrue" ++ "TrueTrueTrue0<" ++ "/property>Display whitespaceTrueTrueFalseTrue" ++ "TrueTrue1Display line endings<" ++ "property name=\"visible\">TrueT" ++ "rueFalseTrueTrueTrue" ++ "2TrueFal" +- "se2TrueFalse/prefs/view/color-scheme-model01TrueTrue" +- "0TrueFalse<b>Colour scheme</b>" +- "TrueFalseTrue2<" +- "/packing>True<" +- "/property>FalseViewFalseTrueFalse66TrueFalse0noneTrueFalse66126TrueFalse3266TrueFalse0Tab width:<" +- "/object>GTK_FILLGTK_FILL" +- "True" +- "False0Tab mode:1" +- "2GTK_FILLGTK_FILLTrueTrue\342\200\242TrueFalseFalseTrueTrue/prefs/editor/tab-width-adjustment" +- "12GTK_FILL" +- "TrueFalse/prefs/editor/tab-mode-store001212GTK_FILLGTK_FILLEnable automatic indentationTrueTrueFalseTrue223" +- "GTK_FILLGTK_FILL<" +- "object class=\"GtkLabel\" id=\"/prefs/editor/indentation/label\">TrueFalse<" +- "/property><b>Indent" +- "ation</b>True" +- "FalseTrue0TrueFalse0noneTrueFalse66126TrueFalse6T" +- "rueFalse0Behaviour:False" +- "True0TrueFalse/prefs/editor/smart-home-end-model01TrueTrue1Tr" +- "ueFalse<b>Home/End Keys</b>TrueFalseTrue11TrueFalseEditor1FalseTrueFalse66TrueFalse0none" ++ "se6Long line margin at column:TrueTrueFalseTrueFalseTrue0TrueFalseTrue\342\200\242TrueFalseFal" ++ "seTrue<" ++ "property name=\"secondary_icon_sensitive\">True/prefs/view/right-margin-adjustmentTrueFalseTrue1FalseTrue3" ++ "Highlig" ++ "ht current lineTrueTrueFalseTrueTrueTrueTrue4<" ++ "property name=\"label\" translatable=\"yes\">Highlight matching bracket" ++ "sTrueTrueFalseTrueTrueTr" ++ "ue5" ++ "Wrap long lin" ++ "esTrueTrueFalseTrueTrueTr" ++ "ue6" ++ "" ++ "TrueFalse<b>Display</b>TrueFalseTrue0<" ++ "/child>" + "True" +- "False66126TrueFalse2Show status barTrueTrueFalseTrueT" +- "rueTrue0Show full filename in title bar0noneTrueFalse66126TrueFalse2Use system monospace fontTrueTrueFalseTrueTrueTrue<" +- "/property>1Rem" +- "ember window sizeTrue<" +- "property name=\"can_focus\">TrueFalseTrueTrueTrue2Remember window positionTrueTrueFalseTrueTrueTrue3Remember window stateTrueTrueFalse<" +- "property name=\"draw_indicator\">TrueTrueTrue4" +- "TrueFalse<b>General</b>TrueFalseT" +- "rue0<" +- "property name=\"visible\">TrueF" +- "alse0noneTru" +- "eFalse66126TrueFalse3266<" +- "object class=\"GtkCheckButton\" id=\"/prefs/window/toolbar/visible-chec" +- "k\">Show toolbarTrueTrueFalseTrue20TrueTrueTrue<" ++ "/object>TrueTrue1TrueFalse<" ++ "property name=\"label\" translatable=\"yes\"><b>Font</b>True<" ++ "/object>FalseTrue1TrueFalse0noneTrueFalse0Style:12GTK_FILLGTK_FILLTrueFalse0Icon Size:23GTK_FILLGTK_" +- "FILLTrue" +- "False/prefs/window/toolbar/style-model011212TrueFalse/prefs/window/toolbar/icon-size-model<" +- "property name=\"active\">011223<" +- "/child>TrueFalse<b>Toolbar</b>TrueFalseTr" +- "ue1" +- "<" +- "property name=\"visible\">TrueF" +- "alse0noneTru" +- "eFalse66126TrueFalse2" +- "Always show tabs even with one fileTrueTrueFalseTrueTrueTrue0Cycled notebook tab switchingTrueTrueFalse0.55000001192092896TrueTrueTrue1True66126True<" ++ "/property>False2TrueFalse/pre" ++ "fs/view/color-scheme-model01Tr" ++ "ueTrue0TrueFalse<b>Colour scheme</b>TrueFalseTrue" ++ "2TrueFalse" ++ "ViewFalseTrueFalse66TrueFalse0n" ++ "oneTrueFalse" ++ "66126TrueFalse3266TrueFalse0Tab width:GTK_FILLGTK_FI" ++ "LLTr" ++ "ueFalse0" ++ "Tab mode:12GTK_FILLGTK_FILLTrueTrue\342\200\242Tr" ++ "ueFalseFalseTrueTrue/pr" ++ "efs/editor/tab-width-adjustment12GTK_FILL" ++ "TrueFalse/prefs/editor/tab-mode-store<" ++ "/property>0" ++ "01212GTK_" ++ "FILLGTK_FILLEnable " ++ "automatic indentationTrueTrueFalseTrue223GTK_FILLGTK_FILLTrueFalse<b>Indentation</b>TrueFalseTrue0TrueFalse0noneT" ++ "rueFalse66126TrueFalse6TrueFalse0Behaviour:FalseTrue0" ++ "TrueFalse/prefs/editor/" ++ "smart-home-end-model01True<" ++ "/property>True1<" ++ "child type=\"label\">TrueFalse<b>Notebook tabs</b><b>Home/End Keys</b>TrueFalseTrue2211TrueFalseWindow" +- "2False" ++ "roperty>Editor" ++ "1False" ++ "TrueFalse66<" ++ "property name=\"visible\">TrueF" ++ "alse0noneTrue" ++ "False66126TrueFalse2Show " ++ "status barTrueTrueFalseTrueTrueTrue0Show full filename in title barTrueTrueFalseTrueTrue<" ++ "/property>True1Remember window sizeTrueTrue" ++ "FalseTrueTrueTrue2Remember win" ++ "dow positionTrueTrueFalseTrueTrueTrue3Remember window state" ++ "TrueTrueFalseTrueTrueTrue4TrueFalse&l" ++ "t;b>General</b>TrueF" ++ "alseTrue0True<" ++ "/property>False0noneTrueFalse66126TrueFalse3266Show toolbarTru" ++ "eTrueFalse" ++ "True2True<" ++ "property name=\"can_focus\">False0" ++ "Style:12GTK_F" ++ "ILLGTK_FILLTrueFalse0" ++ "Icon Size:23GTK_FILLGTK_FILLTrueFalse/prefs/window/toolbar" ++ "/style-model011212TrueFalse/prefs/wi" ++ "ndow/toolbar/icon-size-model0" ++ "11223TrueFalse&" ++ "lt;b>Toolbar</b>True<" ++ "/property>" ++ "FalseTrue1True" ++ "False0noneTrueFalse6<" ++ "property name=\"bottom_padding\">6126" ++ "TrueFalse2Always show tabs even with one" ++ " fileTrueTrueFals" ++ "eTrue<" ++ "packing>TrueTrue0Cycled" ++ " notebook tab switchingTrueTrueFalse0.5500000119209" ++ "2896TrueTrueTrue1<" ++ "/child>TrueFalse<" ++ "property name=\"label\" translatable=\"yes\"><b>Notebook tabs<" ++ "/b>True" ++ "FalseTrue22<" ++ "/property>TrueFalseWindow2False" + }; + +-static const unsigned mousepad_prefs_dialog_ui_length = 30768u; ++static const unsigned mousepad_prefs_dialog_ui_length = 30802u; + diff -Nru mousepad-0.4.0/debian/patches/series mousepad-0.4.0/debian/patches/series --- mousepad-0.4.0/debian/patches/series 2015-11-10 12:51:25.000000000 +0000 +++ mousepad-0.4.0/debian/patches/series 2016-06-30 13:06:42.000000000 +0000 @@ -1 +1,3 @@ +01_prevent-a-g_settings-cycle.patch +02_do-not-manually-update-the-view-theme.patch git-width-mismatch.patch