comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: jump to end of a text widget
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: jump to end of a text widget [message #32486] Mon, 14 October 2002 06:19
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
David Fanning (david@dfanning.com) writes:

>> Is there a possibility to automatic scroll down to the end of the text?
>
> Try something like this, after you have put the new
> text into the text widget:
>
> Widget_Control, textID, Get_Value=theText
> theText = theText[0]
> Widget_Control, textID, Set_Text_Select=[StrLen(theText)-1]

Oh, oh. I just re-read your post. Sounds like you
might have a multi-line text widget, and I stole the
example above from a single-line text widget. You will
have to modify the code to cope with whatever you have,
but you get the idea.

Cheers,

David

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: jump to end of a text widget [message #32487 is a reply to message #32486] Mon, 14 October 2002 06:15 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Dominik Paul (dpaul@ukl.uni-freiburg.de) writes:

> I created a widget_text and put in some text at the end of the last text
> (/append).
> But it looks a little bit bad, when the size of the widget is at the end and
> the text_widget begins write in the text in the invisible part. If you want
> to read it, you have to scroll down.
>
> Is there a possibility to automatic scroll down to the end of the text?

Try something like this, after you have put the new
text into the text widget:

Widget_Control, textID, Get_Value=theText
theText = theText[0]
Widget_Control, textID, Set_Text_Select=[StrLen(theText)-1]

Cheers,

David

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: droplist doesn't work under Linux
Next Topic: Re: returning pointers and simple types from DLM functions

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sun Oct 12 11:19:07 PDT 2025

Total time taken to generate the page: 0.55728 seconds