HP Forums
ATEXTOUT_P - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Software Libraries (/forum-10.html)
+--- Forum: HP Prime Software Library (/forum-15.html)
+--- Thread: ATEXTOUT_P (/thread-21687.html)



ATEXTOUT_P - Tyann - 05-02-2024 02:49 PM

Extension to the TEXTOUT_P function for displaying text with various attributes (bold, underlined, etc. ....) and using a transparency level.
The attached archive contains the hppgm file and detailed instructions in PDF format in English and French.

Extension de la fonction TEXTOUT_P permettant d'afficher du texte avec divers attributs (gras, sous ligné, etc ....) et d'utiliser un niveau de transparence.
Vous trouverez dans l'archive jointe le fichier hppgm et un mode d'emploi détaillé au format PDF en anglais et en français.

Tyann et Komame.


RE: ATEXTOUT_P - Tyann - 05-04-2024 03:20 PM

Bonjour
Voici une petite démo de ce que l'on peut obtenir.

Hello
Here's a quick demo of what you can achieve.


[attachment=13517]


RE: ATEXTOUT_P - komame - 05-07-2024 04:06 PM

Here's a small demonstration of text overlay capabilities during background animation.
[attachment=13524]

To run this program, the library from the first post is required.


RE: ATEXTOUT_P - Tyann - 05-08-2024 05:21 AM

Bonjour komame

Très belle démo, par contre le programme renvoie une erreur (testé sur l'émulateur) : il manque un 'h' sur le #FFFFFF du premier ATEXTOUT_P.
Je me disais aussi que nous avons oublié quelque chose pour la compatibilité avec TEXTOUT_P :
atextout ne renvoie pas de valeur 'X' .

Hello komame

Very nice demo, but the program returns an error (tested on the emulator): the #FFFFFF in the first ATEXTOUT_P is missing an 'h'.
I also thought we'd forgotten something about TEXTOUT_P compatibility:
atextout doesn't return an 'X' value.


RE: ATEXTOUT_P - komame - 05-08-2024 07:11 AM

(05-08-2024 05:21 AM)Tyann Wrote:  Hello komame

Very nice demo, but the program returns an error (tested on the emulator): the #FFFFFF in the first ATEXTOUT_P is missing an 'h'.
I also thought we'd forgotten something about TEXTOUT_P compatibility:
atextout doesn't return an 'X' value.

Hi Tyann,

Thank you for noticing that error. With default settings, the absence of "h" doesn't signal an error, and the program works correctly, so the error would only appear if someone has changed the settings in HOME => Settings, which is why it slipped my attention (because I still have the default settings). In situations where the program uses binary integers, we need to insert the pragma in the program header:
Code:
#pragma mode( separator(.,;) integer(h32) )
and then the "h" at the end of the number becomes optional. The attachment has already been corrected.
Regarding the return of the position of the next character (i.e., what is returned by TEXTOUT_P), here it conflicts with the "frame" format because it excludes the continuation of text in the standard way. To continue the text using the "frame" format, the text needs to be pushed further away so that the next character doesn't overlap with the frame of the previous text. This one format somewhat complicates the implementation of this task.


RE: ATEXTOUT_P - Tyann - 05-08-2024 08:31 AM

Nous avons la longueur du texte grâce à ATEXTSIZE qui tiens compte des attributs, notamment de l'italique.
Si nous renvoyons x + longueur du texte fournie par ATEXTSIZE? cela ne suffit-il pas ?

We have the length of the text thanks to ATEXTSIZE, which takes into account attributes such as italics.
If we return x + text length supplied by ATEXTSIZE? isn't that enough?


RE: ATEXTOUT_P - komame - 05-10-2024 07:11 PM

(05-08-2024 08:31 AM)Tyann Wrote:  We have the length of the text thanks to ATEXTSIZE, which takes into account attributes such as italics.
If we return x + text length supplied by ATEXTSIZE? isn't that enough?

Hi Tyann,
Could you update the file I sent you?


RE: ATEXTOUT_P - Tyann - 05-11-2024 05:23 AM

Bonjour
Voici une nouvelle version ATEXTOUT_P avec quelques modifications, il y a maintenant une version de la documentation en Espagnol et en Allemand, ainsi qu'un écran et un programme de démonstration.

Tyann et Komame.


Hello
Here is a new version of ATEXTOUT_P with a few changes, there is now a version of the documentation in Spanish and German, as well as a screen and a demonstration program.

Tyann and Komame.

[attachment=13543]


RE: ATEXTOUT_P - komame - 05-14-2024 09:45 AM

This is a new version (v1.03) with fixes regarding increased compatibility with TEXTOUT_P (in terms of maximum text length) as well as minor optimizations.
Documentation has also been added in Dutch (NLD), Portuguese (POR), and Simplified Chinese (ZHS).

EDIT (May 17, 2024):
The documentation has been additionally provided in Japanese (JPN).