HP Forums
TEXTOUT_P - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: TEXTOUT_P (/thread-9000.html)



TEXTOUT_P - webmasterpdx - 09-07-2017 08:43 AM

I've seen code that uses a return value from TEXTOUT_P(), but the docs don't tell us what that return value is....
Can anyone tell me what this call returns?
Thx


RE: TEXTOUT_P - Arno K - 09-07-2017 09:09 AM

Syntax:
TEXTOUT_P(text, [G], x, y, [font], [textColor], [width], [backgroundColor])

Draws text on graphic G at position (x, y) using font and textColor. Paints the background before drawing the text using color backgroundColor. If width is specified, does not draw text more than width pixels wide. If backgroundColor is not specified, the background is not erased.

The sizes for font are:

0=current font (default)
1=font 10
2=font 12 (Small)
3=font 14 (Medium)
4=font 16 (Large)
5=font 18
6=font 20
7=font 22

Returns the X coordinate at which the next character of the string should be drawn if the string had more characters

Examples:
TEXTOUT_P("Hello HP Prime",100,100,4,RGB(255,0,0),200,RGB(0,255,255)); FREEZE
__$Demo_PISERIES_P
Arno


RE: TEXTOUT_P - webmasterpdx - 09-07-2017 10:10 AM

That line about what it returns isn't in my version of the docs or the online docs.....is it in a manual you have by chance? If so, please send the link.
Thank you.
-Donald


RE: TEXTOUT_P - DrD - 09-07-2017 11:13 AM

The on-calc help description has that content.


RE: TEXTOUT_P - webmasterpdx - 09-07-2017 11:29 PM

Online help
User manual
on calculator help
Latest release help
Gee, which one am I supposed to find things in when they are all different?
Thx
-D


RE: TEXTOUT_P - toml_12953 - 09-08-2017 12:32 AM

(09-07-2017 11:29 PM)webmasterpdx Wrote:  Online help
User manual
on calculator help
Latest release help
Gee, which one am I supposed to find things in when they are all different?
Thx
-D

It seems like the on calculator help is usually the latest and matches the firmware release. When all else fails, ask here!


RE: TEXTOUT_P - webmasterpdx - 09-08-2017 06:10 AM

I know....I was just being a bit prissy :-)


RE: TEXTOUT_P - DrD - 09-08-2017 10:14 AM

(09-07-2017 11:29 PM)webmasterpdx Wrote:  Online help
User manual
on calculator help
Latest release help
Gee, which one am I supposed to find things in when they are all different?
Thx
-D

So many resources, so little time. (Fortunately, there are reading rooms). It's a good thing, too, because one of the essential skills for job interviews, is locating information.

To your list, I would add, "Trial and Error." Prioritizing your list: {On-Calc Help, User Guide, Online, other resources, Trial and error}. This list works pretty well for me, but, Lord knows, I have been a lifelong student at the school of hard knocks, with masters degree, unlikely.

-Dale-


RE: TEXTOUT_P - cyrille de brébisson - 09-11-2017 05:17 AM

Hello

"It seems like the on calculator help is usually the latest and matches the firmware release. When all else fails, ask here"

I would even update to: "The English version of the on calc help", since the translations can take some time.

Cyrille