text widget question.
Hello All, Need some text widget advice. I writing a GUI and would like to include a 'command line window' - A terminal-like interface to take keyboard input and provide text output (log style output). Looking for a simpler text widget that GtkText. I am currently using a GtkText for output and an GtkEntry for input. And this almost works, but getting the focus into the Entry is a pain. I would like it to be a single window. N-1 lines for a scrolling log, and the last line for keyboard input. And I will add line editing, and history (like tcsh). Some question: 1. Easy solution: Can take GtkText input (key_press_event), and just send these keys to the GtkEntry (as if the user typed them)? 2.Is there a better widget to used. I like to used it in a curses-like fashion ie: wmove(wn,11,11); wprintw(wn, %-3d, spl-pr.numarray); wmove(wn,12,11); wprintw(wn, %-3d, spl-pr.ndr); wmove(wn,13,11); wprintw(wn, %d, spl-pr.cbmode); With color too. ( I know about drawing_areas, but I would like the window to support the X mouse copy function (Right mouse key)). 3. Or can I just fork a color-tty task in a GTK window, that act like an embedded color terminal window. Then I can take my old curses-program have it part of my GUI. Would appreciate any advice thanks, Tony /-\ | Tony Denault| Internet: [EMAIL PROTECTED] | | NASA IRTF, Institute of Astronomy | Phone: (808) 974-4206 | | 1175 Manono St., Bldg 393 | Fax: (808) 974-4207 | | Hilo, Hawaii 96720 | | \-/ ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
Newbie text widget question
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I have programmed using Motif for several years but am just beginning with GTK. I have created a window with two text widgets on it. Each widget displays only part of the text instead of defaulting to the size required to display it all. I have toyed with the word wrapping and text wrapping functions but can't get it to enlarge the window so that all text is displayed. Any hints? Have a good day! - -Vicki +-+ | E-mail: [EMAIL PROTECTED] | |My public key - http://www.thepenguin.org/vicki/key.txt | | My Linux page - http://www.thepenguin.org | +-+ **The best things in life aren't things. -BEGIN PGP SIGNATURE- Version: GnuPG v1.0.4 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE68ZCdvFwCsl/kaSARAq47AJ9UifK4u8gIt8vf/fAWpa+yt6etSgCgj+9u 9mfSqKo08MiOCyTbqVt4DI4= =lnr3 -END PGP SIGNATURE- ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
Newbie text widget question
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I have programmed using Motif for several years but am just beginning with GTK. I have created a window with two text widgets on it. Each widget displays only part of the text instead of defaulting to the size required to display it all. I have toyed with the word wrapping and text wrapping functions but can't get it to enlarge the window so that all text is displayed. Any hints? Have a good day! - -Vicki +-+ | E-mail: [EMAIL PROTECTED] | |My public key - http://www.thepenguin.org/vicki/key.txt | | My Linux page - http://www.thepenguin.org | +-+ **The best things in life aren't things. -BEGIN PGP SIGNATURE- Version: GnuPG v1.0.4 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE68X7lvFwCsl/kaSARArnUAJ48W70ftV1avYnypsF0CiHEr+CrJACeJWuZ +J7QXVl52OQ3mWSYDw1LWJc= =LwXw -END PGP SIGNATURE- ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
Re: Newbie text widget question
Vicki Stanfield [EMAIL PROTECTED] writes: I have programmed using Motif for several years but am just beginning with GTK. I have created a window with two text widgets on it. Each widget displays only part of the text instead of defaulting to the size required to display it all. I have toyed with the word wrapping and text wrapping functions but can't get it to enlarge the window so that all text is displayed. Any hints? If the user can't edit the text to make it huge and you know the text will be smallish, just use GtkLabel. If the user can edit the text or the text might be big, do you really want this to happen? This is the rationale for why the text widget behaves as it does, anyway. Can you explain the situation or behavior you want in more detail? Havoc ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
Re: Newbie text widget question
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 3 May 2001, Havoc Pennington wrote: :: ::Vicki Stanfield [EMAIL PROTECTED] writes: :: I have programmed using Motif for several years but am just beginning :: with GTK. I have created a window with two text widgets on it. Each :: widget displays only part of the text instead of defaulting to the size :: required to display it all. I have toyed with the word wrapping and text :: wrapping functions but can't get it to enlarge the window so that all :: text is displayed. Any hints? :: :: ::If the user can't edit the text to make it huge and you know the text ::will be smallish, just use GtkLabel. If the user can edit the text or ::the text might be big, do you really want this to happen? :: ::This is the rationale for why the text widget behaves as it does, ::anyway. Can you explain the situation or behavior you want in more ::detail? :: ::Havoc Actually I am trying to create a window with some static text in addition to some other widgets. Am I supposed to use a text widget for this or a label widget? Since the text is static, sizing should not be a problem. Have a good day! - -Vicki +-+ | E-mail: [EMAIL PROTECTED] | |My public key - http://www.thepenguin.org/vicki/key.txt | | My Linux page - http://www.thepenguin.org | +-+ **The best things in life aren't things. -BEGIN PGP SIGNATURE- Version: GnuPG v1.0.4 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE68eHTvFwCsl/kaSARAqN6AJ9dV2dPzsfqsk4aVVxe2mXtc5i27gCggI3q TE4dsuvoxtKDC4sjvNl7V6k= =7Qze -END PGP SIGNATURE- ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list