Changeset 1854 in Sophya


Ignore:
Timestamp:
Jan 12, 2002, 1:40:15 AM (24 years ago)
Author:
ansari
Message:

Extension du programme de test de trace de caracteres - Reza 11/01/2001

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PI/Tests/pist.cc

    r1851 r1854  
    301301g->DrawString(2*XSize()/3,24,fszstr[js]);
    302302
     303
     304PIFont fx(14,fn[2]);
     305fx.SetFontSz(mFSize);
     306fx.SetFontAtt(mFAtt);
     307g->SelFont(fx);
    303308int fh,fa,fd;
    304 fh = f.GetFontHeight(fa, fd);
     309fh = fx.GetFontHeight(fa, fd);
    305310cout << " FontSize= " << f.GetFontSize() << " FontHeight= " << fh << endl;
    306 
    307311
    308312
     
    320324g->DrawString(xpos, ypos, s1, PI_HorizontalLeft|PI_VerticalTop);
    321325
    322 xpos = 250;  ypos = 75;
     326xpos = XSize()/2;  ypos = 75;
    323327s1 = "V_Top-H_Center";
    324328g->SelForeground(PI_Red);
     
    328332g->DrawString(xpos, ypos, s1, PI_HorizontalCenter|PI_VerticalTop);
    329333
    330 xpos = 470;  ypos = 75;
     334xpos = XSize()-30;  ypos = 75;
    331335s1 = "V_Top-H_Center";
    332336g->SelForeground(PI_Red);
     
    345349g->DrawString(xpos, ypos, s1, PI_HorizontalLeft|PI_VerticalCenter);
    346350
    347 xpos = 250;  ypos = 150;
     351xpos = XSize()/2;  ypos = 150;
    348352s1 = "V_Center-H_Center";
    349353g->SelForeground(PI_Red);
     
    353357g->DrawString(xpos, ypos, s1, PI_HorizontalCenter|PI_VerticalCenter);
    354358
    355 xpos = 470;  ypos = 150;
     359xpos = XSize()-30;  ypos = 150;
    356360s1 = "V_Center-H_Right";
    357361g->SelForeground(PI_Red);
     
    361365g->DrawString(xpos, ypos, s1, PI_HorizontalRight|PI_VerticalCenter);
    362366 
    363 // --------------- Vertical Bottom -----------------
     367// --------------- Vertical BaseLine -----------------
    364368xpos = 30;  ypos = 250;
    365369s1 = "V_Bottom-H_Left";
     
    368372g->DrawLine(xpos, ypos-10, xpos, ypos+10);
    369373g->SelForeground(PI_Black);
     374g->DrawString(xpos, ypos, s1, PI_HorizontalLeft|PI_VerticalBaseLine);
     375
     376xpos = XSize()/2;  ypos = 250;
     377s1 = "V_Bottom-H_Center";
     378g->SelForeground(PI_Red);
     379g->DrawLine(xpos-50, ypos, xpos+50, ypos);
     380g->DrawLine(xpos, ypos-10, xpos, ypos+10);
     381g->SelForeground(PI_Black);
     382g->DrawString(xpos, ypos, s1, PI_HorizontalCenter|PI_VerticalBaseLine);
     383
     384xpos = XSize()-30;  ypos = 250;
     385s1 = "V_Bottom-H_Center";
     386g->SelForeground(PI_Red);
     387g->DrawLine(xpos-50, ypos, xpos+50, ypos);
     388g->DrawLine(xpos, ypos-10, xpos, ypos+10);
     389g->SelForeground(PI_Black);
     390g->DrawString(xpos, ypos, s1, PI_HorizontalRight|PI_VerticalBaseLine);
     391
     392// --------------- Vertical Bottom -----------------
     393xpos = 30;  ypos = 325;
     394s1 = "V_Bottom-H_Left";
     395g->SelForeground(PI_Red);
     396g->DrawLine(xpos-50, ypos, xpos+50, ypos);
     397g->DrawLine(xpos, ypos-10, xpos, ypos+10);
     398g->SelForeground(PI_Black);
    370399g->DrawString(xpos, ypos, s1, PI_HorizontalLeft|PI_VerticalBottom);
    371400
    372 xpos = 250;  ypos = 250;
     401xpos = XSize()/2;  ypos = 325;
    373402s1 = "V_Bottom-H_Center";
    374403g->SelForeground(PI_Red);
     
    378407g->DrawString(xpos, ypos, s1, PI_HorizontalCenter|PI_VerticalBottom);
    379408
    380 xpos = 470;  ypos = 250;
     409xpos = XSize()-30;  ypos = 325;
    381410s1 = "V_Bottom-H_Center";
    382411g->SelForeground(PI_Red);
     
    489518      sprintf(strg, "Creation StringPosDrawWdg   \n Fenetre No %d ", nbwin);
    490519      sprintf(strg,"StringPosDrawWdg - %d", nbwin);
    491       PIWindow* wp = new PIWindow(this, strg, PIWK_normal,  500, 300, 150, 150);
     520      PIWindow* wp = new PIWindow(this, strg, PIWK_normal,  600, 400, 150, 150);
    492521      wp->SetAutoDelChilds(true);
    493       StringPosDrawWdg* exb  = new StringPosDrawWdg(wp, "sposdrawwdg", 500, 300, 0, 0);
     522      StringPosDrawWdg* exb  = new StringPosDrawWdg(wp, "sposdrawwdg", 600, 400, 0, 0);
    494523      exb->SetBinding(PIBK_fixed,PIBK_elastic,PIBK_elastic,PIBK_elastic);
    495524      wp->SetUserData(exb);
Note: See TracChangeset for help on using the changeset viewer.