Kaydet (Commit) d43aaa86 authored tarafından Nick Treleaven's avatar Nick Treleaven

Fix 'Reflow block' command when at the last paragraph and there's

no last newline (patch by Eugene Arshinov, thanks).



git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4179 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst c1002720
2009-09-13 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
* src/keybindings.c:
Fix 'Reflow block' command when at the last paragraph and there's
no last newline (patch by Eugene Arshinov, thanks).
2009-09-12 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
* src/keybindings.c, src/sciwrappers.c, src/sciwrappers.h,
......
......@@ -2101,8 +2101,12 @@ static void reflow_paragraph(GeanyEditor *editor)
/* deselect last line break */
pos = sci_get_selection_end(sci);
line = sci_get_line_from_position(sci, pos);
pos = sci_get_line_end_position(sci, line - 1);
sci_set_selection_end(sci, pos);
if (line < sci_get_line_count(sci) - 1)
{
/* not last line */
pos = sci_get_line_end_position(sci, line - 1);
sci_set_selection_end(sci, pos);
}
}
split_lines(editor);
if (!sel)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment