Changeset 1534 in Sophya
- Timestamp:
- Jun 15, 2001, 6:17:08 PM (24 years ago)
- Location:
- trunk/SophyaPI/PI
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaPI/PI/pibwdggen.cc
r1034 r1534 288 288 289 289 /* --Methode-- */ 290 void PIBaseWdgGen::PSPrint(PSFile * psf, int ofx, int ofy )290 void PIBaseWdgGen::PSPrint(PSFile * psf, int ofx, int ofy, double scale_x, double scale_y) 291 291 { 292 292 if (!psf) return; 293 PIGraphicPS grpsf(psf, (PIWdg *)this, ofx, ofy );293 PIGraphicPS grpsf(psf, (PIWdg *)this, ofx, ofy, scale_x, scale_y); 294 294 Draw(&grpsf, 0, 0, XSize(), YSize()); 295 295 CallDrawers(&grpsf); -
trunk/SophyaPI/PI/pibwdggen.h
r1034 r1534 73 73 74 74 // PostScript output 75 virtual void PSPrint(PSFile* psf, int ofx = 0, int ofy = 0); 75 virtual void PSPrint(PSFile* psf, int ofx = 0, int ofy = 0, 76 double scale_x=1., double scale_y=1.); 76 77 77 78 // ------ Gestion des Drawers ------ -
trunk/SophyaPI/PI/picontainergen.cc
r440 r1534 125 125 126 126 /* --Methode-- */ 127 void PIContainerGen::PSPrint(PSFile *psf, int ofx, int ofy )127 void PIContainerGen::PSPrint(PSFile *psf, int ofx, int ofy, double scale_x, double scale_y) 128 128 { 129 129 int i; 130 130 if (!psf) return; 131 131 if (!Visible()) return; 132 for(i=0; i<NbChilds(); i++) GetChild(i)->PSPrint(psf, ofx+XPos(), ofy+YPos()); 132 for(i=0; i<NbChilds(); i++) 133 GetChild(i)->PSPrint(psf, ofx+XPos(), ofy+YPos(), scale_x, scale_y); 133 134 return; 134 135 } -
trunk/SophyaPI/PI/picontainergen.h
r329 r1534 51 51 inline PILayoutMgr* GetLayoutMgr() { return(layout); } 52 52 53 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0); 53 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0, 54 double scale_x=1., double scale_y=1.); 54 55 55 56 virtual void Show(); -
trunk/SophyaPI/PI/pigraphps.cc
r547 r1534 43 43 44 44 /* --Methode-- */ 45 PIGraphicPS::PIGraphicPS(PSFile * psf, PIWdg* wdg, double ofx, double ofy) 45 PIGraphicPS::PIGraphicPS(PSFile * psf, PIWdg* wdg, double ofx, double ofy, 46 double scale_x, double scale_y) 46 47 : PIGraphicGen() 47 48 { 48 49 BuildFromPSFile(psf, (double)wdg->XPos()+ofx, (double)wdg->YPos()+ofy, 49 (double)wdg->XSize(), (double)wdg->YSize() ); 50 (double)wdg->XSize(), (double)wdg->YSize(), 51 (double)wdg->XSize()*scale_x, (double)wdg->YSize()*scale_y ); 50 52 } 51 53 … … 54 56 : PIGraphicGen() 55 57 { 56 BuildFromPSFile(psf, x0, y0, dx, dy );58 BuildFromPSFile(psf, x0, y0, dx, dy, dx, dy); 57 59 } 58 60 … … 71 73 72 74 /* --Methode-- */ 73 void PIGraphicPS::BuildFromPSFile(PSFile * psf, double x0, double y0, double dx, double dy) 75 void PIGraphicPS::BuildFromPSFile(PSFile * psf, double x0, double y0, double tx, double ty, 76 double dx, double dy) 74 77 { 75 78 mPSOut = psf; … … 86 89 SelMarker(1, PI_DotMarker); 87 90 88 if (psf) psf->NewBloc(x0, y0, dx, dy, dx, dy);91 if (psf) psf->NewBloc(x0, y0, tx, ty, dx, dy); 89 92 mXmin = mYmin = 0.; 90 93 mXmax = dx; mYmax = dy; -
trunk/SophyaPI/PI/pigraphps.h
r382 r1534 9 9 { 10 10 public: 11 PIGraphicPS(PSFile * psf, PIWdg* wdg, double ofx=0., double ofy=0.); 11 PIGraphicPS(PSFile * psf, PIWdg* wdg, double ofx=0., double ofy=0., 12 double scale_x=1., double scale_y=1.); 12 13 PIGraphicPS(PSFile * psf, double x0, double y0, double dx, double dy); 13 14 virtual ~PIGraphicPS(); … … 74 75 75 76 protected: 76 void BuildFromPSFile(PSFile * psf, double x0, double y0, double dx, double dy); 77 void BuildFromPSFile(PSFile * psf, double x0, double y0, double tx, double ty, 78 double dx, double dy); 77 79 78 80 PSFile * mPSOut; /* Fichier PostScript */ -
trunk/SophyaPI/PI/pistzwin.cc
r329 r1534 172 172 173 173 /* --Methode-- */ 174 void PIStackWindow::PSPrint(PSFile *psf, int ofx, int ofy )174 void PIStackWindow::PSPrint(PSFile *psf, int ofx, int ofy, double scale_x, double scale_y) 175 175 { 176 176 if (!psf) return; 177 177 int k; 178 178 for(k=0; k<NbChilds(); k++) { 179 psf->NewPage((double)XSize() , (double)YSize(),PI_Auto);180 GetChild(k)->PSPrint(psf, ofx, ofy );179 psf->NewPage((double)XSize()*scale_x, (double)YSize()*scale_y,PI_Auto); 180 GetChild(k)->PSPrint(psf, ofx, ofy, scale_x, scale_y); 181 181 } 182 182 } -
trunk/SophyaPI/PI/pistzwin.h
r329 r1534 41 41 42 42 virtual void SetLayoutMgr(PILayoutMgr* nlay); 43 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0); 43 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0, 44 double scale_x=1., double scale_y=1.); 44 45 45 46 inline void DispNext() { ((PIStackLayout*)layout)->DispNext(); } -
trunk/SophyaPI/PI/piversion.h
r1503 r1534 2 2 #define PIVERSION_H_SEEN 3 3 4 #define PI_VERSIONNUMBER 2. 854 #define PI_VERSIONNUMBER 2.90 5 5 6 6 #endif -
trunk/SophyaPI/PI/piwdggen.cc
r1034 r1534 266 266 267 267 /* --Methode-- */ 268 void PIWdgGen::PSPrint(PSFile *psf, int ofx, int ofy )268 void PIWdgGen::PSPrint(PSFile *psf, int ofx, int ofy, double scale_x, double scale_y) 269 269 { 270 270 char str[256]; 271 271 272 272 if (!psf) return; 273 psf->NewBloc((double)ofx+XPos(), (double)ofy+YPos(), (double)XSize(), (double)YSize(), 274 (double)XSize(), (double)YSize()); 275 psf->DrawBox(0., 0., (double)XSize(), (double)YSize()); 273 double dx = (double)XSize()*scale_x; 274 double dy = (double)YSize()*scale_y; 275 psf->NewBloc((double)ofx+XPos(), (double)ofy+YPos(), dx, dy, dx, dy); 276 psf->DrawBox(0., 0., dx, dy); 276 277 sprintf(str,"PIWdgGen::PSPrint() Kind=%ld Name= %s", kind(), Nom().c_str()); 277 278 // N.R. 07/08/99 FontName specifie dans DrawString() -
trunk/SophyaPI/PI/piwdggen.h
r1034 r1534 100 100 virtual bool IfSensitive()=0; 101 101 102 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0); 102 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0, 103 double scale_x=1., double scale_y=1.); 103 104 104 105 // Gestion de copier-coller -
trunk/SophyaPI/PI/piwindowgen.cc
r329 r1534 75 75 76 76 /* --Methode-- */ 77 void PIWindowGen::PSPrint(PSFile *psf, int ofx, int ofy )77 void PIWindowGen::PSPrint(PSFile *psf, int ofx, int ofy, double scale_x, double scale_y) 78 78 { 79 79 if (!psf) return; 80 80 //int ori; 81 81 //ori = (XSize() > YSize()) ? LANDSCAPE : PORTRAIT ; 82 psf->NewPage((float)XSize() , (float)YSize(),PI_Auto);83 PIContainerGen::PSPrint(psf, ofx, ofy );82 psf->NewPage((float)XSize()*scale_x, (float)YSize()*scale_y,PI_Auto); 83 PIContainerGen::PSPrint(psf, ofx, ofy, scale_x, scale_y); 84 84 } 85 85 -
trunk/SophyaPI/PI/piwindowgen.h
r329 r1534 22 22 virtual long kind() {return ClassId; } 23 23 24 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0); 24 virtual void PSPrint(PSFile *psf, int ofx=0, int ofy=0, 25 double scale_x=1., double scale_y=1.); 25 26 26 27 inline void AutoHideOnClose(bool ahc=true) { mAHC = ahc; }
Note:
See TracChangeset
for help on using the changeset viewer.