gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
some off-by-one issues, fixing selection of line-ends. (#50323)
This commit is contained in:
parent
f9cc44268e
commit
4c44499b3f
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2001-08-07 <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
|
* gtk/gtktextdisplay.c (render_para, gtk_text_layout_draw): Fix
|
||||||
|
some off-by-one issues, fixing selection of line-ends. (#50323)
|
||||||
|
|
||||||
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
2001-08-07 Matthias Clasen <matthiasc@waldgeist.poet.de>
|
||||||
|
|
||||||
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
* gtk/gtkhsv.c (gtk_hsv_map, gtk_hsv_unmap): Reinstate these
|
||||||
|
@ -539,7 +539,7 @@ render_para (GdkDrawable *drawable,
|
|||||||
y + PANGO_PIXELS (baseline),
|
y + PANGO_PIXELS (baseline),
|
||||||
FALSE);
|
FALSE);
|
||||||
|
|
||||||
if (selection_start_index < byte_offset + line->length &&
|
if (selection_start_index <= byte_offset + line->length &&
|
||||||
selection_end_index > byte_offset) /* Some selected */
|
selection_end_index > byte_offset) /* Some selected */
|
||||||
{
|
{
|
||||||
GdkRegion *clip_region = get_selected_clip (render_state, layout, line,
|
GdkRegion *clip_region = get_selected_clip (render_state, layout, line,
|
||||||
@ -757,8 +757,8 @@ gtk_text_layout_draw (GtkTextLayout *layout,
|
|||||||
&line_end,
|
&line_end,
|
||||||
line, byte_count - 1);
|
line, byte_count - 1);
|
||||||
|
|
||||||
if (gtk_text_iter_compare (&selection_start, &line_end) < 0 &&
|
if (gtk_text_iter_compare (&selection_start, &line_end) <= 0 &&
|
||||||
gtk_text_iter_compare (&selection_end, &line_start) > 0)
|
gtk_text_iter_compare (&selection_end, &line_start) >= 0)
|
||||||
{
|
{
|
||||||
if (gtk_text_iter_compare (&selection_start, &line_start) >= 0)
|
if (gtk_text_iter_compare (&selection_start, &line_start) >= 0)
|
||||||
selection_start_index = gtk_text_iter_get_line_index (&selection_start);
|
selection_start_index = gtk_text_iter_get_line_index (&selection_start);
|
||||||
|
Loading…
Reference in New Issue
Block a user