GetTextAlign not found
Issue #148
resolved
and BTW TA_UPDATECP is not supported
SetTextAlign(FDC, Align or TA_UPDATECP);
Comments (6)
-
repo owner -
reporter I know
this is the code I use
procedure TForm1.FormPaint(Sender: TObject); var p: PChar; dc: HDC; x: Integer; s: TSize; begin p := 'Hello World !'; dc := Canvas.Handle; x := 10; SetBkColor(dc, $FFFFFF); // not supported SetTextColor(dc, 0); TextOut(dc, x, 10, p, 3); GetTextExtentPoint32(dc, p, 3, s); // the length parameter seems to be ignored Inc(x, s.cx); SetBkColor(dc, $FF9933); SetTextColor(dc, $FFFFFF); TextOut(dc, x, 10, @p[3], 5); GetTextExtentPoint32(dc, @p[3], 5, s); Inc(x, s.cx); SetBkColor(dc, $FFFFFF); SetTextColor(dc, 0); TextOut(dc, x, 10, @p[8], 5); SetTextAlign(DC, TA_UPDATECP); // no need to care about the text size (GetTextExtentExPoint was used to know the number of characters to draw) MoveToEx(DC, 10, 30, nil); // just set the origin SetBkColor(dc, $FFFFFF); SetTextColor(dc, 0); TextOut(dc, 0, 0, p, 3); // draw from origin and move the current position (x and y should be ignored) SetBkColor(dc, $FF9933); SetTextColor(dc, $FFFFFF); TextOut(dc, 0, 0, @p[3], 5); SetBkColor(dc, $FFFFFF); SetTextColor(dc, 0); TextOut(dc, 0, 0, @p[8], 5); end;
-
repo owner - changed status to resolved
Fixed at 0.99l
-
repo owner - changed status to open
-
repo owner GetTextAlign works at 0.99
-
repo owner - changed status to resolved
Fixed at 0.99m
- Log in to comment
How you use this function ? The point that we don't have plan to support whole API set.