Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3368: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3370: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3371: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3372: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
OrbWorks Community Forum • View topic - Text Box or Equivalent

Text Box or Equivalent

Discuss PocketC for CE (including Desktop Edition)

Postby rvennes on Wed Feb 21, 2001 8:50 pm

How would I go about creating a textbox that shows multiple lines of text. From the PDF documentation, createctrl only has EDIT which only accepts a single line without wrapping. The others COMBOBOX, LISTBOX don't seem to do what I want.

Ideally, I'd like a text box with a scroll or track bar on the right to move up and down through the text.

Thanks...

rvennes@jbase.com
rvennes
 
Posts: 2
Joined: Mon Feb 19, 2001 10:58 pm
Location: USA

Postby Justinespinosa on Thu Feb 22, 2001 6:34 am

You must include pcheader.h and windefs,h (i don't remember in wich one it is)

then just create an edit that is multiline:
<pre id=code><font face=courier size=2 id=code>
createctrl("EDIT","<Text in the edit line1>/r/n<Text line 2>",WS_VISIBLE|ES_MULTILINE|ES_AUTOVSCROLL|WS_VSCROLL,512,x,y,h,w,id);
</font id=code></pre id=code>
This edit box will be a "Word WRAP" text box, it doesn't scroll text horizontally to do that just add ES_AUTOHSCROLL|WS_HSCROLL (HSCROLL to add a scrollbar)

J.Espinosa

OUTS Softwares
J.Espinosa

OUTS Softwares
Justinespinosa
 
Posts: 156
Joined: Wed Dec 06, 2000 2:30 pm
Location: Switzerland

Postby airdrik on Mon Feb 26, 2001 2:43 pm

<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
You must include pcheader.h and windefs,h (i don't remember in wich one it is)

<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>

Include them both, because pcheader.h has the macros for initializing the controls and windefs.h has the constants for sending messages to the controls.
airdrik
 
Posts: 26
Joined: Fri Feb 09, 2001 3:25 pm

Postby guy on Tue Feb 27, 2001 8:55 am

To get the text contents to move to the next line without using wrapping you will need to include (char) 10 and (char) 13 pairs in the text for line breaks.



Guy
Guy
[url]mailto:pcform@pcform.net[/url]
http://www.pcform.net
PocketC CE API interface: http://www.networkdynamics.net/PCForm.html#library
PCForm and CE API forum: http://www.networkdynamics.net/forum
guy
 
Posts: 879
Joined: Thu Dec 07, 2000 8:58 am
Location: United Kingdom

Postby Justinespinosa on Tue Feb 27, 2001 2:36 pm

Yes, it's what i have written:
(char)10 is "\r" and (char)13 is "\n"

J.Espinosa

OUTS Softwares
J.Espinosa

OUTS Softwares
Justinespinosa
 
Posts: 156
Joined: Wed Dec 06, 2000 2:30 pm
Location: Switzerland

Postby airdrik on Tue Feb 27, 2001 5:26 pm

If, when creating the control, you add ES_WANTRETURN then when you type something into the edit control and hit enter it adds a new line to the edit. I don't think there is anything that makes it auto word-wrap, though.
airdrik
 
Posts: 26
Joined: Fri Feb 09, 2001 3:25 pm

Postby guy on Wed Feb 28, 2001 8:24 am

Has anyone got a definitive document describing where \r and \n work, and where they don't?

In some circumstances instead of getting carriage return and linefeed you just get a "blob" character.

I'm not sure where in the parser these escaped characters are translated.


Guy
Guy
[url]mailto:pcform@pcform.net[/url]
http://www.pcform.net
PocketC CE API interface: http://www.networkdynamics.net/PCForm.html#library
PCForm and CE API forum: http://www.networkdynamics.net/forum
guy
 
Posts: 879
Joined: Thu Dec 07, 2000 8:58 am
Location: United Kingdom


Return to PocketC for CE

Who is online

Users browsing this forum: No registered users and 2 guests

cron