How can I incorporate in the following simple programming extract a PEN control (f.e. a PEN width 5) to become a BOX with thicker lines
DEFINE FONT fntArial3 NAME "Arial" SIZE 0, -12 BOLD OF oPrn
nRow2:=3*fntArial3:nHeight
nCol2:=4*fntArial3:nWidth
PRINT oPrn FROM USER
PAGE
oPrn:Box(nRow2,nCol2,nRow2+=8.5*fntArial3:nHeight,nCol2+=40*fntArial3:nWidth)
….
PEN oPen
- Enrico Maria Giordano
- Posts: 7355
- Joined: Thu Oct 06, 2005 8:17 pm
- Location: Roma - Italia
- Contact:
Re: PEN oPen
Just pass oPen as the fifth parameter to the Box() method.
EMG
EMG
Re: PEN oPen
and how to introduce the PEN command before passing it as the fifth parameter
I tried already with
define PEN oPen width 5 for example
but it did not work?
I tried already with
define PEN oPen width 5 for example
but it did not work?
Re: PEN oPen
DId You define the pen like
define PEN oPen width 5 OF oPRINT
sample lineprinting :
oPRINT:Line ( nFil, nCol, nTop, nBot, oPen )
regards
Uwe
define PEN oPen width 5 OF oPRINT
sample lineprinting :
oPRINT:Line ( nFil, nCol, nTop, nBot, oPen )
regards
Uwe
Last edited by ukoenig on Thu Nov 01, 2018 5:17 pm, edited 1 time in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.
- Enrico Maria Giordano
- Posts: 7355
- Joined: Thu Oct 06, 2005 8:17 pm
- Location: Roma - Italia
- Contact:
Re: PEN oPen
5 is too small. Try 50. Anyway, this is a working sample:
EMG
Code: Select all
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oPrn, oPen
PRINT oPrn PREVIEW
DEFINE PEN oPen WIDTH 50
PAGE
oPrn:Ellipse( 0, 0, 1000, 2000, oPen )
ENDPAGE
ENDPRINT
DELETEOBJECT( oPen )
RETURN NIL
Re: PEN oPen
The thickness from a pen must be calculated in dependence to the used printer! (or give the OF oPrint clausula as ukoenig say!)
- Enrico Maria Giordano
- Posts: 7355
- Joined: Thu Oct 06, 2005 8:17 pm
- Location: Roma - Italia
- Contact:
Re: PEN oPen
I don't see any difference between using or not OF oPrn.
EMG
EMG