changing dynamically the font0 or ini settings

Author: francois.moritz@hewitt.com (fmoritz)

hello

we are facing uniface is not able to change every settings defined in the INI files at runtime.

Of course we could use a 3GL to write into the ini file (asn file) but uniface is not able to take the modification into account as soon this setting have already been read.

example : fonts. (font0 or others)

if you create 2 reports which needs different matrix resolution (defined with  font0) you are not able to run them into  the same session.

Uniface reads the ini file's settings and fonts as soon it encounters a widgets which needs it and keep them to the end, so these settings are kept in the memory till the end of the session...

It'd be very usefull if it'd be possible to oblige uniface to re-read the inifile and INI settings by emptying what's in the memory.

So a second component / report (or process) could take advantages from a new definition without having to create a second windows process detached.

Of course in a interactiv mode it'd be weird to changes font0 ...but there are many other fonts or settings which could be usefull to be changed.

example : $clear(font0) ???????

regards

 

 

1 Comment

  1. Hi,

    Since 9.3 you can use for example

       $1 = $setting("usys", "[upi]msglines", "USYSDATA")
    or
       $setting("usys", "[upi]msglines", "USYSDATA") = 40

    to get & set runtime ini settings for settings that come from sections [upi], [application], [debug], [toolbar] and [hotkeys] in the ini file. Setting a value only changes the value Uniface works with, it does not change the ini file. To update the ini file, use "" or the actual file name i.s.o "usys".

    For fonts, which are in [screen], there is no provision yet, unfortunately. Note also that the $setting function is undocumented and unsupported at this time.

    Etienne


    Author: etienne (etienne_thijsse@compuware.com)