diff options
author | Pablo Barciela <[email protected]> | 2018-08-17 04:14:11 +0200 |
---|---|---|
committer | Pablo Barciela <[email protected]> | 2018-08-19 05:34:29 +0200 |
commit | 708bfc0c84daf1f3a44ab3f0d87845f9a1429b5d (patch) | |
tree | 1d918863f9a93c1fd336a20368aab5b2e3cff2f1 | |
parent | e28def84292e2bf1d1fa9699c040a9072bcc4548 (diff) | |
download | pluma-708bfc0c84daf1f3a44ab3f0d87845f9a1429b5d.tar.bz2 pluma-708bfc0c84daf1f3a44ab3f0d87845f9a1429b5d.tar.xz |
pluma-sort-plugin: avoid extra empty line
Fixes https://github.com/mate-desktop/pluma/issues/153
-rw-r--r-- | plugins/sort/pluma-sort-plugin.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/plugins/sort/pluma-sort-plugin.c b/plugins/sort/pluma-sort-plugin.c index 67a3a1ce..d512f4b8 100644 --- a/plugins/sort/pluma-sort-plugin.c +++ b/plugins/sort/pluma-sort-plugin.c @@ -434,10 +434,12 @@ sort_real (SortDialog *dialog) &start, lines[i], -1); - gtk_text_buffer_insert (GTK_TEXT_BUFFER (doc), - &start, - "\n", - -1); + + if (i < (num_lines - 1)) + gtk_text_buffer_insert (GTK_TEXT_BUFFER (doc), + &start, + "\n", + -1); last_row = lines[i]; } |