home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / c / library / dos / window / ultrawin / uw_help5.hlp < prev    next >
Encoding:
Text File  |  1992-01-20  |  20.5 KB  |  525 lines

  1. `co(4,7);────────────────────────── /// General Macros ────────────────────────────────`co();
  2.     UltraWin also makes extensive use of macros ( defined in UW.H ) for simple
  3.     operations that do not justify the overhead of a function, and make your
  4.     programs more readable.  The following are for general use.
  5.  
  6. `co(10,1);/// hibyte`co();
  7.     #define hibyte(c)              (uchar) ((c) >> 8)
  8.     Yields the most significant byte of integer c.
  9.  
  10. `co(10,1);/// lobyte`co();
  11.     #define lobyte(c)              (uchar) ((c) & 0x00ff)
  12.     Yields the least significant byte of integer c.
  13.  
  14. `co(10,1);/// lower`co();
  15.     #define lower (x, y)         (x < y) ? x : y
  16.     Yields the lesser of the values x and y.
  17.  
  18. `co(10,1);/// range`co();
  19.     #define range(l,b,h)         ((((b) >= (l)) && ((b) <= (h))))
  20.     Yields a 1 if b is between l and h inclusive.
  21.  
  22. `co(10,1);/// swap`co();
  23.     #define swap(a,b,c)          ((c) = (a), (a) = (b), (b) = (c))
  24.     Swaps the values a and b utilizing a temporary c.
  25.  
  26. `co(10,1);/// upper`co();
  27.     #define upper (x, y)         (x > y) ? x : y
  28.   Yields the greater of the values x and y.
  29.  
  30. `co(4,7);────────────────────────── /// Window Macros ─────────────────────────────────`co();
  31.     Many of the things you do with windows are only accomplished with the
  32.     window marcros.  The macros will allow you to perform several forms of
  33.     input/output to a window, change the window attributes, move the window
  34.     cursor within the window, and more.  A close look at these macros will
  35.     give you some insight into how UltraWin uses the window structure.
  36.  
  37. `co(10,1);/// cls`co();
  38.     #define cls()                                 (setmem(Screen, V_cols * V_rows * 2, 0))
  39.     Clears the entire screen to black.
  40.  
  41. `co(10,1);/// mv_cs`co();
  42.     #define mv_cs(c,r,wnp)                ((wnp)->csr_x = (c), (wnp)->csr_y = (r))
  43.     Moves the "soft" cursor in window wnp to the column and row c and r.
  44.     
  45. `co(10,1);/// wn_att`co();
  46.     #define wn_att(a,wnp)                 ((wnp)->att = (a))
  47.     Sets the window attribute in wnp to the value a.
  48.  
  49. `co(10,1);/// wn_bdratt`co();
  50.     #define wn_bdratt(a,wnp)            ((wnp)->bdr_att = (a))
  51.     Sets the window boder attribute in wnp to the value a.    This is
  52.     the complement to the wn_att macro.
  53.     
  54. `co(10,1);/// wn_bdr_color`co();
  55.     #define wn_bdr_color(f,b,wnp) ((wnp)->bdr_att = ((b) << 4) | (f))
  56.     Sets the border foreground and background colors in window wnp.  This
  57.     is the complement to the wn_color macro.
  58.  
  59. `co(10,1);/// wn_color`co();
  60.     #define wn_color(f,b,wnp)         ((wnp)->att = ((b) << 4) | (f))
  61.     Sets the foreground and background colors in window wnp.    This is
  62.     done by setting the window attribute accordingly.
  63.     
  64. `co(10,1);/// wn_name`co();
  65.     #define wn_name(n, wnp)             ((wnp)->name = (n))
  66.     Sets the name at the top of window wnp to the string n.
  67.  
  68. `co(10,1);/// wn_name_loc`co();
  69.     #define wn_name_loc(l, wnp)     ((wnp)->name_loc = (l))
  70.     Sets the location of the name in window wnp to left, right, or
  71.     centered.
  72.  
  73. `co(10,1);/// wn_read`co();
  74.     #define wn_read( wnp )                (wn_io( IN, BUFF, (wnp)))
  75.     Pulls what is actually on the screen under the window into the
  76.     window itself!    This is like wn_save, but instead of pulling the
  77.     area under the window into the save/restore buffer, it pulls it
  78.     into the window.
  79.  
  80. `co(10,1);/// wn_restore`co();
  81.     #define wn_restore( wnp )         (wn_io(OUT, SAVE, (wnp)))
  82.     Restores the area saved (by the macro wn_save) under the window wnp.
  83.     
  84. `co(10,1);/// wn_rfsh`co();
  85.     #define wn_rfsh( wnp )                (wn_io(OUT, BUFF, (wnp)))
  86.     Redraws (refreshes) the window wnp.
  87.  
  88. `co(10,1);/// wn_save`co();
  89.     #define wn_save( wnp )                (wn_io( IN, SAVE, (wnp)))
  90.     Saves the area under the window wnp to the window save area for later
  91.     restoration.
  92.  
  93. `co(4,7);─────────────────────────── /// Font/EGA Control ─────────────────────────────`co();
  94.  
  95.  ┌──────────────────────────────────────────────────────────────────────────┐    
  96.  │          `keyword(encode_color,/// encode_color);                      `keyword(decode_color,/// decode_color);                  │
  97.  │          `keyword(load_font,/// load_font);                         `keyword(save_font,/// save_font);                     │
  98.  │          `keyword(install_font,/// install_font);                      `keyword(get_font_info,/// get_font_info);                 │
  99.  │          `keyword(blink_enable,/// blink_enable);                      `keyword(replicate_enable,/// replicate_enable);              │
  100.  │          `keyword(set_block_ab,/// set_block_ab);                      `keyword(rom8x8,/// rom8x8);                        │
  101.  │          `keyword(rom8x14,/// rom8x14);                           `keyword(rom8x16,/// rom8x16);                       │
  102.  │          `keyword(read_palette,/// read_palette);                      `keyword(read_palette_all,/// read_palette_all);              │
  103.  │          `keyword(write_palette,/// write_palette);                     `keyword(write_palette_all,/// write_palette_all);             │
  104.  └──────────────────────────────────────────────────────────────────────────┘
  105.  
  106.         These functions are specific to EGA/VGA boards and are advanced
  107.     features. We do not attempt to explain all the details and quirks of the
  108.     EGA/VGA video subsystems.  We recommend you have some reference material
  109.     detailing the EGA/VGA video system to supplement the material presented
  110.     here.
  111.  
  112.         UltraWin gives you the ability to use our own EGA/VGA fonts, or create
  113.     your own with our powerful font editor.  UltraWin also lets you use a full
  114.     16 background colors, and even change the EGA/VGA palette.  However, it is
  115.     not possible to actually read the palette registers on an EGA board.  We
  116.     resolve this deficiency by keeping a "shadow" palette that is initialized
  117.     to the standard EGA values.  When you read/write the palette registers,
  118.     you are also accessing this "shadow" area.
  119.  
  120. `co(10,1);/// encode_color`co();   `keyword(source,[UW_FONT.C]~encode_color);
  121.       Takes the individual red, green, and blue color components and encodes
  122.     them into a format suitable for the EGA/VGA palette registers, returning
  123.     this value as an integer. see also `keyword(decode_color,///decode_color);
  124.  
  125. Prototype:
  126.     void encode_color(int r, int g, int b);
  127.  
  128. Parameters:
  129. `co(11,1);    int r, g, b`co();
  130.         Integers containing each color component.
  131.  
  132. Usage:
  133.     int color, r = 2, g = 3, b = 1;
  134.     ...
  135.     color = encode_color( r, g, b );
  136.  
  137. `co(10,1);/// decode_color`co();   `keyword(source,[UW_FONT.C]~decode_color);
  138.       Takes an EGA/VGA color encoded value as it would be stored in a palette
  139.     register and returns the individual Red, Green, and Blue components.  See
  140.     also `keyword(encode_color,/// encode_color);
  141.  
  142. Prototype:
  143.     void decode_color(int color, int *r, int *g, int *b);
  144.  
  145. Parameters:
  146. `co(11,1);    int color;`co();
  147.         The EGA/VGA encoded color value.
  148. `co(11,1);    int *r, *g, *b`co();
  149.         Integer pointers to store each color component.
  150.  
  151. Usage:
  152.     int color, r, g, b;
  153.     color = random(64);
  154.     ...
  155.     decode_color( color, &r, &g, &b );
  156.  
  157. `co(10,1);/// load_font`co();   `keyword(source,[UW_FONT.C]~load_font);
  158.       Loads a font pattern file into memory.  The fonts are stored int raw
  159.     format, with no header information residing in the file.  As an example,
  160.     let's say we have a file containing 256 8x14 characters.  The first
  161.     characters' pattern is contained in the first 14 bytes, the second in
  162.     bytes 15-28, and so on.  You should either allocate the appropriate
  163.     number of bytes and pass the pointer to this function or pass the name
  164.     of a sufficiently large global array of bytes. Upon a successful load,
  165.     the function will return the number of scan lines that are in each
  166.     character, or 0 upon failure.  See also `keyword(save_font,///save_font);
  167.  
  168. Prototype:
  169.     int load_font( uchar *font, char *fname );
  170.  
  171. Parameters:
  172. `co(11,1);    uchar *font;`co();
  173.         A pointer to an area large enough to hold the font pattern data.
  174. `co(11,1);    char  *fname;`co();
  175.         A pointer to the filename that contains the font pattern data.
  176.  
  177. Usage:
  178.     uchar Font8x14[256][14];                                  /* global array */
  179.     int Scan_lines;
  180.     ...
  181.     Scan_lines = load_font( Font8x14, "8x14icon.fnt");
  182.  
  183. `co(10,1);/// save_font`co();   `keyword(source,[UW_FONT.C]~save_font);
  184.       Saves a font pattern from memory into a file.  This is the complement
  185.   of `keyword(load_font,/// load_font);
  186.   
  187. Prototype:
  188.     int save_font( uchar *font, char *fname, int scan_lines );
  189.  
  190. Parameters:
  191. `co(11,1);    uchar *font;`co();
  192.         A pointer to an area containing the font pattern data.
  193. `co(11,1);    char  *fname;`co();
  194.         A pointer to the filename to which to save the font data.
  195. `co(11,1);    int   scan_lines;`co();
  196.         The number of scan_lines the font contains (typically 8/14/16).
  197.  
  198. Usage:
  199.     uchar Font8x14[256][14];                                  /* global array */
  200.     ...
  201.     save_font( Font8x14, "8x14ICON.FNT", 14 );
  202.  
  203. `co(10,1);/// install_font`co();   `keyword(source,[UW_FONT.C]~install_font);
  204.       Installs a font loaded into memory, into the EGA/VGA bios area.  Two
  205.     sets of 256 characters can be resident at one time.  The "block" parameter
  206.     determines which set to install.  If "setmode" is non-zero, the video mode
  207.     will be reset.
  208.   
  209. Prototype:
  210.     void install_font( uchar *font, int block, int offset, int cnt,
  211.                                          int scan_lines, int setmode );
  212.  
  213. Parameters:
  214. `co(11,1);    uchar *font;`co();
  215.         A pointer to an area containing the font pattern data.
  216. `co(11,1);    int   block;`co();
  217.         The character set in which to load this font. (0 or 1).
  218. `co(11,1);    int   offset;`co();
  219.         The character offset to load the new font data, typically 0.
  220. `co(11,1);    int   cnt;`co();
  221.         The number of characters to install (max 256).
  222. `co(11,1);    int   scan_lines;`co();
  223.         The number of scan_lines the font contains (typically 8/14/16).
  224. `co(11,1);    int   set_mode;`co();
  225.         If non-zero, the video mode will be reset.
  226.  
  227. Usage:
  228.     uchar Font8x14[256][14];                                  /* global array */
  229.     ...
  230.     load_font( Font8x14, "8x14icon.fnt" );
  231.   install_font( Font8x14, 1, 0, 256, 14, 0 );
  232.  
  233. `co(10,1);/// get_font_info`co();   `keyword(source,[UW_FONT.C]~get_font_info);
  234.       Returns the address, number of scan_lines and video character rows of
  235.     the current font.
  236.     
  237. Prototype:
  238.     uchar far *get_font_info( int type, int *scan_lines, int *rows );
  239.  
  240. Parameters:
  241. `co(11,1);    int   type;`co();
  242.     2 - get address of ROM 8x14 font
  243.     3 - get address of ROM 8x8 font
  244.     4 - get address of second half of ROM 8x8 font
  245.     5 - get address of ROM 9x14 alternate font
  246.     6 - get address of ROM 8x16 font
  247.     7 - get address of ROM 9x16 alternate font
  248. `co(11,1);    int   *scan_lines;`co();
  249.         A pointer to an integer in which to store the number of scan lines in 
  250.     the current font.
  251. `co(11,1);    int   *rows;`co();
  252.         A pointer to an integer in which to store the number of character rows
  253.     for the current screen mode.
  254.  
  255. Usage:
  256.     int scan_lines, rows;
  257.     uchar far  *font;
  258.     ...
  259.     font = get_font_info( 2, &scan_lines, &rows );
  260.  
  261. `co(10,1);/// blink_enable`co();   `keyword(source,[UW_FONT.C]~blink_enable);
  262.       Enables or disables blinking on EGA/VGA systems. When the blink bit is
  263.     disabled, all 256 possible color combinations (16 foreground, 16
  264.     background) can be displayed at one time with no blinking.  If enabled,
  265.     those character cells whose background color is 8-15 will blink.
  266.  
  267. Prototype:
  268. void blink_enable(int state);
  269.  
  270. Parameters:
  271. `co(11,1);    int   state;`co();
  272.         1 to enable blink, 0 to disable blink.
  273.  
  274. Usage:
  275.     ...
  276.     blink_enable(1);
  277.  
  278. `co(10,1);/// replicate_enable`co();   `keyword(source,[UW_FONT.C]~replicate_enable);
  279.       Enables or disables 9th pixel replication for the 32 characters 0xC0 -
  280.     0xDF on EGA/VGA boards.  The use of this function depends on the video
  281.     card in use.  Some cards (especially in monochrome modes) use a 9 pixel
  282.     wide cell, even though the font is only 8 pixels wide. This usually causes
  283.     no problem as the hardware hides this from us.  However, when performing
  284.     line drawing or other operations where characters must join, a gap may
  285.     exist.  The hardware is capable of replicating the 8th bit into the 9th
  286.     bit to allow for continuous characters. The hardware only does this for
  287.     the line drawing character block 0xC0 - 0xDF. In short, if you modify your
  288.     own fonts and create new borders, lines, etc. that need to be continuous,
  289.     it is recommended that you store these characters in this area and enable
  290.     replication.  No other character cells will be affected.
  291.  
  292. Prototype:
  293.     void replicate_enable(int state);
  294.  
  295. Parameters:
  296. `co(11,1);    int   state;`co();
  297.         1 to enable 9th pixel replication, 0 to disable replication.
  298.  
  299. Usage:
  300.     ...
  301.     replicate_enable(1);
  302.  
  303. `co(10,1);/// set_block_ab`co();   `keyword(source,[UW_FONT.C]~set_block_ab);
  304.       Sets the two possible active fonts as primary and secondary.  Both
  305.     blocks can be set to the same mode.  For example, if we load a standard
  306.     8x14 font into block 0, and an 8x14 icon font into block 1, we might say
  307.     "set_block_ab(0,1)".  This sets the 8x14 as the primary font and the icon
  308.     font as secondary. (Displayed if the background is 8-15).  If
  309.     "set_block_ab(1,0)" is called, the two fonts will be effectively switched.
  310.     "Set_block_ab(0,0)" will always display the 8x14 font regardless of
  311.     attribute settings.
  312.  
  313. Prototype:
  314.     void set_block_ab(int a, int b);
  315.  
  316. Parameters:
  317. `co(11,1);    int   a;`co();
  318.         0 - set font 0 as primary font, 1 - set font 0 as alternate font.
  319. `co(11,1);    int   b;`co();
  320.         0 - set font 1 as primary font, 1 - set font 1 as alternate font.
  321.  
  322. Usage:
  323.     ...
  324.     load_font( Font8x14, "8x14.fnt" );
  325.   install_font( Font8x14, 0, 0, 256, 14, 0 );
  326.     load_font( Font8x14, "8x14icon.fnt" );
  327.   install_font( Font8x14, 1, 0, 256, 14, 0 );
  328.     set_block_ab(0,1);            /* 8x14 - block 0, 8x14icon block 1 */
  329.  
  330. `co(10,1);/// rom8x8`co();   `keyword(source,[UW_FONT.C]~rom8x8);
  331.       Loads the video BIOS 8x8 font into the desired block and optionally
  332.     resets the video mode
  333.  
  334. Prototype:
  335.     void rom8x8(int block, int setmode);
  336.  
  337. Parameters:
  338. `co(11,1);    int   block;`co();
  339.         0 - load font into block 0, 1 - load font into block 1.
  340. `co(11,1);    int   setmode;`co();
  341.         0 - do not reset video mode. 1- set video mode.
  342.  
  343. Usage:
  344.     ...
  345.     rom8x8(0,1);                                    /* load as primary, reset video mode  */
  346.  
  347. `co(10,1);/// rom8x14`co();   `keyword(source,[UW_FONT.C]~rom8x14);
  348.       Loads the video BIOS 8x14 font into the desired block and optionally
  349.     resets the video mode.
  350.  
  351. Prototype:
  352.     void rom8x14(int block, int setmode);
  353.  
  354. Parameters:
  355. `co(11,1);    int   block;`co();
  356.         0 - load font into block 0, 1 - load font into block 1.
  357. `co(11,1);    int   setmode;`co();
  358.         0 - do not reset video mode. 1- set video mode.
  359.  
  360. Usage:
  361.     ...
  362.     rom8x14(1,0);                                    /* load as alternate, don't reset     */
  363.  
  364. `co(10,1);/// rom8x16`co();   `keyword(source,[UW_FONT.C]~rom8x16);
  365.       Loads the video BIOS 8x16 font into the desired block and optionally
  366.     resets the video mode (VGA only).
  367.  
  368. Prototype:
  369.     void rom8x16(int block, int setmode);
  370.  
  371. Parameters:
  372. `co(11,1);    int   block;`co();
  373.         0 - load font into block 0, 1 - load font into block 1.
  374. `co(11,1);    int   setmode;`co();
  375.         0 - do not reset video mode. 1- set video mode.
  376.  
  377. Usage:
  378.     ...
  379.     rom8x16(0,0);                                    /* load as primary, don't reset mode  */
  380.  
  381. `co(10,1);/// read_palette`co();   `keyword(source,[UW_FONT.C]~read_palette);
  382.       Reads a single palette register and returns the value. To determine the
  383.     RGB components, see `keyword(decode_color,/// decode_color); above.
  384.  
  385. Prototype:
  386.     int read_palette( int pnum );
  387.  
  388. Parameters:
  389. `co(11,1);    int   pnum;`co();
  390.         The color palette index to read (0-15).
  391.  
  392. Usage:
  393.     int color;
  394.     ...
  395.     color = read_palette(6);
  396.  
  397. `co(10,1);/// read_palette_all`co();   `keyword(source,[UW_FONT.C]~read_palette_all);
  398.       Reads all 16 palette registers and stores the values into the desired
  399.     area.
  400.  
  401. Prototype:
  402.     int read_palette_all( uchar *vals );
  403.  
  404. Parameters:
  405. `co(11,1);    uchar  *vals;`co();
  406.         A pointer to an array (at least 16 bytes) in which to store the values.
  407.  
  408. Usage:
  409.     uchar colors[16];
  410.     ...
  411.     read_palette_all(colors);
  412.  
  413. `co(10,1);/// write_palette`co();   `keyword(source,[UW_FONT.C]~write_palette);
  414.       Writes a value to a single palette register.  To specify the color in
  415.     RGB components, see `keyword(encode_color,/// encode_color); above.
  416.  
  417. Prototype:
  418.     int write_palette( int pnum, uchar val );
  419.  
  420. Parameters:
  421. `co(11,1);    int   pnum;`co();
  422.         The color palette index to write (0-15).
  423. `co(11,1);    uchar val;`co();
  424.         The color palette value.
  425.  
  426. Usage:
  427.     ...
  428.   write_palette(6, encode_color(1,3,2));
  429.  
  430. `co(10,1);/// write_palette_all`co();   `keyword(source,[UW_FONT.C]~write_palette_all);
  431.       Writes values to all palette registers.
  432.  
  433. Prototype:
  434.     int write_palette_all( uchar *vals );
  435.  
  436. Parameters:
  437. `co(11,1);    uchar *vals;`co();
  438.         The 16 color palette values.
  439.  
  440. Usage:
  441.     char palette[16] =
  442.     { 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x14,    0x07,
  443.         0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f };
  444.     ...
  445.   write_palette_all(palette);
  446.  
  447. `color(RED,LIGHTGRAY);──────────────────────────  /// Graphics Support ─────────────────────────────`color();
  448.  
  449.       UltraWin is a unique library in that although primarily designed for
  450.     text modes it has the capability to use EGA/VGA graphic modes as well.
  451.     This is due to the flexibility of UltraWin's text output routines.  It was
  452.     a fairly simple task for us to route all text output through one routine
  453.     which places one character on the screen.  This does not slow down normal
  454.     text output whatsoever, as all output is routed through this special g_ch
  455.     function only when the global Graphics flag is set.
  456.   
  457.       Please understand though, UltraWin does not add a graphics libarary or
  458.     any other graphics routines other than the output of a single character.
  459.     All UltraWin output is still cell based.  This is no great limitation as
  460.     you can use a third-party graphics library (or the one bundled with your
  461.     compiler) to do all your lines, polygons, circles, etc.  To get UltraWin
  462.     to use graphics, first use your graphics library to put the video into
  463.     either EGA 640x350x16 or VGA 640x480x16 mode and call `keyword(init_uw_graphics,/// init_uw_graphics);.
  464.     It's that easy!
  465.   
  466.       Since UltraWin gives you this flexibility the library can become quite
  467.   literally hardware independent.  For instance, all that would be necessary
  468.   to make UltraWin work with custom hardware ( or even a dumb terminal )
  469.   would be to write ONE routine (g_ch) that outputs a single character on
  470.   the display device, and then call init_uw_graphics.  All output would then
  471.   go through g_ch.  Please see `keyword(g_ch,/// g_ch); for more information.
  472.  
  473. `co(10,1);/// init_uw_graphics`co();   `keyword(source,[UW_GRAPH.C]~init_uw_graphics);
  474.       Initializes UltraWin to support EGA/VGA graphics output.
  475.  
  476. Prototype:
  477.     int init_uw_graphics( int xres, int yres, int font_rows,
  478.                           int font_spacing, int seg, int off );
  479.  
  480. Parameters:
  481.   Parameters:
  482. `co(11,1);  int xres, yres`co();   - resolution in pixels for EGA/VGA
  483. `co(11,1);  int font_rows`co();    - number of scan lines for current font
  484. `co(11,1);  int font_spacing`co(); - number of scan lines between characters
  485. `co(11,1);  int seg`co();          - graphics segment (-1 sets default 0xa000)
  486. `co(11,1);  int off`co();          - graphics offset  (-1 sets default 0x0000)
  487.  
  488. Usage:
  489.     ...
  490.     init_uw_graphics( 640, 350, 14, 14, -1, -1 );
  491.  
  492. `co(10,1);/// g_ch`co();   `keyword(source,[UW_GRAPH.C]~g_ch);
  493.       Outputs a single character to the graphics screen.  This function will
  494.     not normally be called by you.  It is a very important function for those
  495.     of you interested in using UltraWin in graphic modes.  All UltraWin output
  496.     will go through this routine when the Graphics flag is set.  This feature
  497.     gives you the power to write your own g_ch to support other graphics
  498.     standards, dumb-terminals, and virtually any non-standard hardware.
  499.     (Please note that when the global variable G_opt is set, g_ch will not
  500.     draw if the character is already on the screen in the proper colors.)
  501.     
  502.         It is very important to understand what happens here.  We simply replace
  503.     output routines - no other graphics support is provided - UltraWin works
  504.     exactly as it does in text mode.  It will not save/restore graphics areas
  505.     under windows - you must do this yourself, if you wish.
  506.     
  507.         Also note that this function, along with get_font_info and install_font
  508.     are only compilable under the Borland compilers, Microsoft users can link
  509.     the object module into their programs if need be.  Of course if you use the
  510.     library for your compiler, then it is all automatic.
  511.  
  512. Prototype:
  513.     int g_ch( int c, int r, int v );
  514.  
  515. Parameters:
  516.   Parameters:
  517. `co(11,1);    int c;`co(); - col (UltraWin col 0-V_cols - 1, not pixel col).
  518. `co(11,1);  int r;`co(); - row (UltraWin row 0-V_rows - 1, not pixel row).
  519. `co(11,1);  int v;`co(); - character value (0-255).
  520.  
  521. Usage:
  522.     ...
  523.     g_ch(10, 15, 'x');
  524.  
  525.