Re: A83: _sfont_len doesn't work?
[Prev][Next][Index][Thread]
Re: A83: _sfont_len doesn't work?
In accordance with the prophecy, Sebastian Grössl uttered:
>
> In one of my programs I wanted to use call _sfont_len, but it didn't work!
> I did not get the results I wanted!
>
> In the Ti-documentation, they write:
> ;--------------------------------------------------------
> ; _sfont_len : return the length of varible width
> ; display char
> ;
> ; input : hl = char value
> ; output : b = width of char
> ; hl + 1 = 1st byte of char font
> ;-----------------------------------------------------------
>
> I tried it with h=char value and l=char value and hl=(char value), but for b I only got 0, 21h, or something negative. What is the problem? Please help me!
> Greez
> Sebastian
It wants the character number multiplied by 8.
Took a while to figure out. Will take a while to figure out why. =)
(The intenal font table is of course 8 bytes per character, but there's no
apparent reason why _SFONT_LEN shouldn't do the multiplication.)
Linus
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
"Good judgment comes from experience, and a lot of that comes from bad
judgment."
--Will Rogers
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
References: