Page 1 of 1
oPen with printer
Posted: Thu Jan 23, 2020 2:19 pm
by byte-one
If i define a pen with DEFINE PEN.... then the width of pen are different in methods fron tPrinter()!
oPrn:Box( nZeile+nPenw/2,nPenw/2,nNextzeile,oPrn:nHorzRes()-nPenw/2, oPen)
oPrn:line(nZeile,linksrand,nZeile,rechtsrand,oPen)
Re: oPen with printer
Posted: Thu Jan 23, 2020 3:28 pm
by karinha
Code: Select all
PRINT oPrn NAME "Relatório do Certificado do Aluno" PREVIEW MODAL
DEFINE FONT oFontDisc NAME "Arial" SIZE 0, -10 BOLD OF oPrn
DEFINE FONT oFont NAME "Arial" SIZE 0, -10 BOLD OF oPrn
DEFINE FONT oFontSubl NAME "ARIAL" SIZE 0, -10 BOLD UnderLine OF oPrn
DEFINE FONT oFontList NAME "ARIAL" SIZE 0, -22 BOLD OF oPrn
DEFINE PEN oPen1 WIDTH 12 COLOR CLR_HBLUE OF oPrn
DEFINE PEN oPen2 WIDTH 12 COLOR CLR_AMARELO OF oPrn
DEFINE PEN oPen3 WIDTH 4 COLOR CLR_BLACK OF oPrn
oPrn:SetPage(9) //->Folha A4
oPrn:SetPortrait() //->Vertical
ResLinha := oPrn:nLogPixely()/2.54
ResColuna := oPrn:nLogPixelx()/2.54
PAGE
nLinTopLog1 := 0.90 //->Lado de Cima - Topo - Inicio
nColTopLog1 := 0.50 //->Lado Esquerdo - Inicio
nLinBotLog1 := 14.60 //->Final da Linha - Lado de Baixo
nColBotLog1 := 20.50 //->Final do Logo - Lado Direito
nLinTopLog2 := 1.20 //->Lado de Cima - Topo - Inicio
nColTopLog2 := 0.70 //->Lado Esquerdo - Inicio
nLinBotLog2 := 14.40 //->Final da Linha - Lado de Baixo
nColBotLog2 := 20.30 //->Final do Logo - Lado Direito
oPrn:Cmtr2Pix( @nLinTopLog1, @nColTopLog1 )
oPrn:cmtr2Pix( @nLinBotLog1, @nColBotLog1 )
oPrn:Box( nLinTopLog1, nColTopLog1, nLinBotLog1, nColBotLog1, oPen1 )
oPrn:Cmtr2Pix( @nLinTopLog2, @nColTopLog2 )
oPrn:cmtr2Pix( @nLinBotLog2, @nColBotLog2 )
oPrn:Box( nLinTopLog2, nColTopLog2, nLinBotLog2, nColBotLog2, oPen2 )
Regards.
Re: oPen with printer
Posted: Thu Jan 23, 2020 4:23 pm
by MaxP
How the pen is created in the source code ?
Re: oPen with printer
Posted: Thu Jan 23, 2020 4:39 pm
by byte-one
DEFINE PEN oPen1 WIDTH nPixel COLOR CLR_HBLUE
Re: oPen with printer
Posted: Thu Jan 23, 2020 4:53 pm
by MaxP
Try
DEFINE PEN oPen1 WIDTH nPixel COLOR CLR_HBLUE OF oPrn
Re: oPen with printer
Posted: Thu Jan 23, 2020 6:37 pm
by byte-one
Also with the clausula "OF oPrn" the oPrn:line and oPrn:box are different!