Hi all,

I've been trying to do something that, I guess, is pretty easy, which
is to place the cursor in the beginning of a textview's buffer.

Here's the code snippet where I'm trying to do it (and if it's not the
best way of  doing that, somebody please let me know; I'm pretty new
to both python and pygtk):

        textview1 = mainWindow.get_widget("textview1")
        (...)
        textview1.set_editable(False)
        buffer1.set_text("my text here (...)")
        textview1.set_wrap_mode(gtk.WRAP_WORD)
        textview1.move_visually(
textview1.get_buffer().get_end_iter(),
textview1.get_buffer().get_char_count() * -1)

Does anybody know what I'm doing wrong? If I print the last command's
result, it prints "True", so it means my cursor should be placed where
I'm telling it to be, no? (And, of course, if there is a simpler way
to do that, I'd love to know also.)

Thanks for any help,

-- 
Mírian Bruckschen
_______________________________________________
pygtk mailing list   [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to