acmfiu@serss0.fiu.edu (ACMFIU) (02/24/91)
i setup a window with no title. now, when i moveto local coordinates (0, 5) with 0 as vertical and 5 as horizontal, why or why when i drawchar ('a') doesn't the 'a' get drawn to the upper left corner of the window. it seems like there is an imaginary window title there and the (0, 5) gets offset from that. i don't want this. how can i do what i want? albert
4225_5117@uwovax.uwo.ca (02/25/91)
In article <2592@kluge.fiu.edu>, acmfiu@serss0.fiu.edu (ACMFIU) writes: > i setup a window with no title. now, when i moveto local coordinates (0, 5) > with 0 as vertical and 5 as horizontal, why or why when i drawchar ('a') > doesn't the 'a' get drawn to the upper left corner of the window. it seems > like there is an imaginary window title there and the (0, 5) gets offset > from that. i don't want this. how can i do what i want? > > albert Simple, the current vertical pen position is used as the position for the baseline of the font. In the case of Shaston this is probably about 7 or 8 pixels from the top of the character. To get the text to appear where you want you must take this top-to-baseline height into account and position the pen down far enough. Mike
campbellb@gtephx.UUCP (Brian Campbell) (02/26/91)
In article <2592@kluge.fiu.edu>, acmfiu@serss0.fiu.edu (ACMFIU) writes: > i setup a window with no title. now, when i moveto local coordinates (0, 5) > with 0 as vertical and 5 as horizontal, why or why when i drawchar ('a') > doesn't the 'a' get drawn to the upper left corner of the window. it seems I believe that it draws characters above and to the right of the coordinates. In other words, you should specify a coordinate that represents the lower left corner of the first character. For example, to display a character that is eight pixels high, to the left of the screen, and at the very top of the screen, use coordinates (0,7).