I have problems whit messages I send to ringhio, Ringio seams to wont to divide my lines at any place, in middle of hex number and it does not care if has been a line feed char before in the line, is there anyway to get better control of this? The return char, produces strange symbols.
My ringhio messages looks like total crap.
please help
(NutsAboutAmiga)
Basilisk II for AmigaOS4 AmigaInputAnywhere Excalibur and other tools and apps.
I already report this issue to m3x when i translated the Ringhio messages for AmiUpdate, however since then nothing changes, hope it will be for the next release
@m3x I think the biggest problem is that it is (apparently) automatically splitting the text (into several lines) in the MIDDLE of words. The secondary problem is that it does not handle new-line characters as you would expect.
the lines gets short and short, and not all the info is displayed because of the extra inserted line feeds, and as you can see the line feeds are not inserted where the is space between word, it inserted at any place in middle of words also.
The text below display the text as it should have been displayed.
Quote:
Guru Error: 0x15038005
Recoverable alert alert.exe (695ee610)
0x00030000 General error: AG_OpenLib
0x00008005 Alert object: AO_MathLib
0x15000001 timer: AN_TMBadReq
(NutsAboutAmiga)
Basilisk II for AmigaOS4 AmigaInputAnywhere Excalibur and other tools and apps.
I think the biggest problem is that it is (apparently) automatically splitting the text (into several lines) in the MIDDLE of words. The secondary problem is that it does not handle new-line characters as you would expect.
As far as I can see it does not split lines in the middle of "words" but in the middle of "numbers"
In fact after a bit of testing with the arexx script in the documentation I can see that it words wraps on 'nonalpha' characters rather than on white space, which causes LiveForIts numbers to get split.
That other factor is that "\n" in the message text causes line breaks in the display, but appears not to be taken in account when calculating the points at which Ringhio adds addiational linebreaks causing the odd linelengths.
In fact after a bit of testing with the arexx script in the documentation I can see that it words wraps on 'nonalpha' characters rather than on white space, which causes LiveForIts numbers to get split.
Might be a good idea to make it word wrap only on non-alphanumeric characters instead of all non-alpha characters.
Or to let it take into account the \n characters. It's quite easy to imagine the algorithm which might be used for splitting the lines - calculate the width and move back to the next previous space, which is then replaced with a \n. That wouldn't take into account any \n which is already in the string, and is only noticed once it's sent to be displayed.
It should be trivial to account for existing newlines in the code... Maybe for 4.2?
AFAIK it's not documented how Ringhio wraps the text. Two possibilities: - either it's based on character count, - either it's based on a certain pixel width (which would mean amount of text actually displayed depends on the screen resolution and text size).
AFAIK it's not documented how Ringhio wraps the text. Two possibilities:
It's not as far as I can see.
Quote:
- either it's based on character count,
It is. A simple experiment will show that Text in the title and body are wrapped at 30 characters, if one of those happens to be a "\n" hen it is treated ;ike any other for wrap calculations.
text code for experiments
/* Small script for testing Ringhio */
options results
NL = X2C('09')
address RINGHIO
'REGISTERAPP APP=TESTRINGHIO ICON="SYS:Documentation/Ringhio/rx_testringhio.rexx" This is a test app entry'
say RESULT
'RINGHIO APP=TESTRINGHIO CLOSEONDC SCREEN="FRONT" PRI=9 IMG=SYS:Prefs/Presets/Ringhio/test.png TITLE="0123456789*N1123456789212345678931234567894123456789" IMGVALIGN=1
TEXT="01234567891123456789212345678931234567894123456789you see this little popup message, ,./;.,./;.,)(*&^%$£"!£$%^&*() and a wink icon, 134567890 it means Ringhio is working OK"'
say RESULT
Text in the title and body are wrapped at 30 characters, if one of those happens to be a "\n" hen it is treated like any other for wrap calculations.
Would be nice if "\n" was treated the same way as it is in requesters, wouldn't it? If only for the sake of consistency. Imagine a program that gives the user an option to receive notifications in the form of either a requester or a Ringhio pop-up. Under the current circumstances, the programmer would have to prepare the message differently for the requester and for Ringhio - which I think is wrong.
Nice work keeping the wiki up to date. The wiki page on application library is really well done. If the whole wiki keeps to this level of greatness it will be an amazing resource.