Changes between Version 1 and Version 2 of Docs/Prog/Manual/DeviceSupport/Display


Ignore:
Timestamp:
11/30/09 10:32:08 (14 years ago)
Author:
Don Wilson
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Docs/Prog/Manual/DeviceSupport/Display

    v1 v2  
    44A special button font is provided with characters that are formatted to be used as buttons for “Zero”, “Tare”, “Gross”, “Net”, “Units”, and “Print”.
    55
     6=== Fonts ===
     7Fonts are stored in the 825 in files with the Linux nano-X (rockbox) format .fnt. The font folder is /mnt/nand/fonts.
     8
     9The 825 graphics device driver and the lib825 application library provide functions for loading fonts into RAM memory and displaying text using the loaded fonts
     10
     11'''!ReadFont'''
     12
     13The lib825 function “!ReadFont” is used to read and load a font file into RAM.
     14
     15The parameter nFont is a font number which should be in the range: 1 – 29
     16
     17The parameter pszFilename is the full path and filename of the font such as:
     18
     19“/mnt/nand/fonts/Font788_11x2.fnt” (Reminder: Linux path and filenames are case sensitive)
     20
     21'''int''' '''!ReadFont'''('''int''' nFont, '''const''' '''char'''* pszFilename)
     22
     23The return value is zero if successful or one if an error occurred.
     24
     25'''!DisplayStr'''
     26
     27The lib825 function “!DisplayStr” is used to display a text string using a specified font.
     28
     29The parameter nFont is a font number of a font previously loaded into RAM using !ReadFont
     30
     31The parameter x is the X coordinate
     32
     33The parameter y is the Y coordinate
     34
     35The parameter dsplogic is the display logic which may be DSP_LOGIC_SET, DSP_LOGIC_XOR, DSP_LOGIC_RESET, or DSP_LOGIC_OVERWRITE
     36
     37'''#define''' DSP_LOGIC_SET 0
     38
     39'''#define''' DSP_LOGIC_XOR 1
     40
     41'''#define''' DSP_LOGIC_RESET 2
     42
     43'''#define''' DSP_LOGIC_OVERWRITE 3
     44
     45'''void''' !DisplayStr('''int''' nFont, '''int''' x, '''int''' y, '''int''' dsplogic, '''const''' '''char'''* p)
     46
     47'''Font788.exe'''
     48
     49The Windows utility program Font788.exe, previously part of the !SmartWeigh install is updated to allow converting 788 fonts or TTF fonts to 825 format. (If your PC does not have the appropriate support files to run this program run the “vcredist.exe” program to install them).
     50
     51Make sure all font copyrights are observed. Obtain proper licensing for any fonts to be used.
     52
     53A new menu option “Load built-in font…” is provided.
     54
     55This allows loading the standard built in fonts.
     56
     57The “File” “Export” option now allows “Export to 825 format...”
     58
     59The “Font” menu has an additional feature “Information” which allows detailed viewing and some limited editing of fonts.
     60
     61Font characters may be modified by clicking the squares representing each pixel. If a pixel which is on is clicked it will be turned off. If a pixel which is off is clicked it will be turned on.
     62
     63'''Remote Control using custom fonts'''
     64
     65To use apps using custom fonts with remote control the !DspApplet.class should be at least version 1.09
     66
     67The version will show at the bottom of the applet.
     68
     69A fonts link should be created in the html folder:
     70
     71This allows the applet to access the fonts in /mnt/nand/fonts from the default html location.
    672[[Top]]