scrolling in program for wxTextCtrl
Ondra Holub
ondra.holub at post.cz
Thu Sep 6 00:34:25 PDT 2007
On 6 Zá , 07:31, m.arte... at yahoo.com (muntean iulian artenie) wrote:
> Hi there everyone !
> I want to make 2 wxTextCtrl multiline windows
> scroll simultaneously (if the user scrolls in one
> window the other should scroll by itself to the same
> positition). The windows have the same number of
> lines.
> This is on MSW (Windows Xp) platform.
> With classes derived from wxScrolledWindow this is
> easy because you have the Scroll(x, y) method but
> wxTextCtrl is not derived from this class.
> I tried the ShowPosition(pos) method but this
> scrolls only vertically and only by a certain number
> of lines (i mean it does't scroll between lines).
> I don't know how to use the ScrollWindow method
> belonging to the wxWindow class so i'm out of ideas.
> Thanks !!!
>
> ____________________________________________________________________________________
> Got a little couch potato?
> Check out fun summer activities for kids.http://search.yahoo.com/search?fr=oni_on_mail&p=summer+activities+for...
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: wx-users-unsubscr... at lists.wxwidgets.org
> For additional commands, e-mail: wx-users-h... at lists.wxwidgets.org
Hi. Maybe could work following (I am not sure, it is just idea): You
could create wxTextCtrl and place it in wxScrolledWindow. Then use
capability of wxScrolledWindow for scrolling. However you could have
problems with cursor position.
More information about the wx-users
mailing list