MODULE clavier;

FROM tigr IMPORT TigrPtr,tigrWindow,tigrFree,tigrClosed, tigrClear, tigrUpdate, TPixelType,
                tigrLine, TK_ESCAPE, tigrKeyDown, tigrReadChar, tfont, tigrPrint,tigrFill,
                tigrCircle, tigrRect, tigrFillCircle,  tigrTime, tigrError, tigrClip, 
                tigrFillRect, tigrTextWidth, tigrTextHeight, tigrLoadImage, tigrReadFile,
                tigrBitmap, TIGR_2X, tigrSetPostFX, tigrMouse,tigrBlit, tigrBlitAlpha,
                 tigrEncodeUTF8, TK_RIGHT,tigrKeyHeld, TK_SPACE, TK_LEFT;

FROM helper IMPORT tigrRGB, tigrRGBA;
FROM DynamicStrings IMPORT String, InitString;
FROM InOut IMPORT Write, WriteLn, WriteCard,WriteString, WriteHex;
FROM Delay IMPORT Delay;

VAR
    touche : CARDINAL;
    ecran : TigrPtr;
    titre : String;

BEGIN
    titre := InitString("你好");
    ecran := tigrWindow(320, 240, titre, 0);
    WHILE NOT (tigrClosed(ecran ) > 0) DO
        tigrClear(ecran, tigrRGB(80H, 90H, 0A0H));
        WriteHex(tigrReadChar(ecran), 7); WriteLn;
        tigrUpdate(ecran);

        Delay(100);
    END;
    tigrFree(ecran);
END clavier.