gtk_text_get_point() == cursor position?
- From: Matthias Moeller <mattes ice robin de>
- To: gtk-list redhat com
- Subject: gtk_text_get_point() == cursor position?
- Date: Sat, 20 Jun 1998 22:53:18 +0200 (MEST)
Hello
I found a problem with the method gtk_text_get_point() of
GtkTextWidget. It seems that the method reports the wrong
cursor position after moving the cursor around with the
cursor-keys.
After inserting characters, the reported position is ok.
This is because the method gtk_text_insert() calls the
internal function advance_mark_n(&text->point, length)
which updates the point position.
On the other hand, the internal function move_cursor_ver()
(which is called after cursor-key press) only updates
text->cursor_mark, but not text->point. text->point then
later gets updated before the next key press is evaluated
in gtk_text_key_press().
I don't fully understand the code and especially the
difference between the two GtkPropertyMarks "point" and
"cursor_mark".
Maybe somebody could explain whether I found a bug or a
feature ;-) Thanks in advance,
Max
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]