How to make a multi-line TGTextEntry?

How to make a multi-line TGTextEntry?

Hi,

Use TGTextEdit if you need to manipulate multiple lines. TGTextEntry is a simple one line widget.

Cheers, Ilka

Thank you for reply.
Could you post some example?
Since I’m not familiar with this class. I tried some but always see gray edge even I set kDoubleBorder off. Is there any method to solve this?

Thanks

In guitest.C, I add one line
fMain->Print();
after line 2413. ( in Editor::Editor() ,just after fMain->AddFrame(fOK, fL2); )

And I run it and click “Open Editor”, it gives me this error.

root [1] TGTransientFrame: id=50332117 parent=64 x=0 y=0 w=600 h=400
sh: -c: line 1: syntax error near unexpected token -P' sh: -c: line 1:(null) -P(null)’

*** Break *** write on a pipe with no one to read it
TGTextButton: id=50332136 parent=50332117 x=0 y=0 w=42 h=22

I use root 5.14 on RedHat

Anyone can explain this?

Hi,

I will investigate this behavior. It could be related to not set printer command and default printer in your environment. You could click with the right mouse button on the text area and select ‘Print’ from the context menu. A simple dialog should pop-up asking you for this information. It will show default values, which should be replaced. Please try that way and let me know does it work for you.

Cheers, Ilka

PS:You were asking for an example and I see you have found one we have in guitest.C.

Oh, I see. I thought it only printed Frame Structure on screen. Now it works.
But don’t the reason, just because of TGTextEdit? I guess.

Thanks.

Hi,

The reason is related to the default printer and print command settings, which do not fit your environment settings. After you enter the required information via the print dialog, everything is on place and it works.

Cheers, Ilka

Oh, I see. I check the src code and now know the reason.

Thank you very much.