Como imprimir textos con orientacion diferente
Moderator: Rathinagiri
Como imprimir textos con orientacion diferente
Buen dia a todos
alguien sabe como puedo imprimir un en dos orientaciones DIFente orientacion
T
E
X
T
O
---texto
GRACIAS
alguien sabe como puedo imprimir un en dos orientaciones DIFente orientacion
T
E
X
T
O
---texto
GRACIAS
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
Como imprimir textos con orientacion diferente
Te faltó dar más detalles de como estás imprimiendo. Si en modo gráfico, en modo texto ? Si puede ser en PDF...
En HaruPDF hay: HPDF_PAGE_PORTRAIT y HPDF_PAGE_LANDSCAPE
En HPDF tambien: HPDF_ORIENT_PORTRAIT y HPDF_ORIENT_LANDSCAPE
En HMG Print system tambien: PRINTER_ORIENT_PORTRAIT y PRINTER_ORIENT_LANDSCAPE
Si es una solución para modo Texto, puede utilizar los comandos internos de la impresora. Por ejemplo, para las impresoras HP LASER and DESKJET:
Landscape: CHR(27)+'&l1O'
Portrait: CHR(27)+'&l0O'
En HaruPDF hay: HPDF_PAGE_PORTRAIT y HPDF_PAGE_LANDSCAPE
En HPDF tambien: HPDF_ORIENT_PORTRAIT y HPDF_ORIENT_LANDSCAPE
En HMG Print system tambien: PRINTER_ORIENT_PORTRAIT y PRINTER_ORIENT_LANDSCAPE
Si es una solución para modo Texto, puede utilizar los comandos internos de la impresora. Por ejemplo, para las impresoras HP LASER and DESKJET:
Landscape: CHR(27)+'&l1O'
Portrait: CHR(27)+'&l0O'
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
Re: Como imprimir textos con orientacion diferente
Pablo, I don't think you've understood well.
It's impossible in the straight way.
You should define function to print char by char changing row by line height and setting column to the same value:
It's impossible in the straight way.
You should define function to print char by char changing row by line height and setting column to the same value:
Code: Select all
For i:=1 to len(cTextToPrint)
@ nRow+nLineHeight*(i-1), nCol print substr(cTextToPrint,i,1)
Next i
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
Como imprimir textos con orientacion diferente
Ohhh sorry, you are right Marek. I missunderstood, thank you to advise.
If the queston is:
Posible to print images
Possible to save image to file
Possible to display text in different orientation thru BossTaurus like as:
BT_TEXT_NORMAL_ORIENTATION
BT_TEXT_VERTICAL_ASCENDANT
BT_TEXT_VERTICAL_DESCENDANT
BT_TEXT_DIAGONAL_ASCENDANT
BT_TEXT_DIAGONAL_DESCENDANT
Then I believe would it be posible too. I also believe that could be not necessary to save image to a file for printing.
If the queston is:
Posible to print images
Possible to save image to file
Possible to display text in different orientation thru BossTaurus like as:
BT_TEXT_NORMAL_ORIENTATION
BT_TEXT_VERTICAL_ASCENDANT
BT_TEXT_VERTICAL_DESCENDANT
BT_TEXT_DIAGONAL_ASCENDANT
BT_TEXT_DIAGONAL_DESCENDANT
Then I believe would it be posible too. I also believe that could be not necessary to save image to a file for printing.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
-
- Posts: 1275
- Joined: Tue Sep 03, 2013 4:22 am
- Location: Tecámac, México
Re: Como imprimir textos con orientacion diferente
Hola jucar_es,
También es posible haciendo una rutina para que las muestre en coordenadas o posición que quieras!, en Clipper una vez baje un demo que lo hacia, claro que era en modo consola, pero ahorita no lo tengo a la mano, a lo mejor lo perdí, pero creo que sustrayendo cada carácter del texto a imprimir se puede hacer!
Saludos, y por falta de tiempo no puedo hacer un demo
También es posible haciendo una rutina para que las muestre en coordenadas o posición que quieras!, en Clipper una vez baje un demo que lo hacia, claro que era en modo consola, pero ahorita no lo tengo a la mano, a lo mejor lo perdí, pero creo que sustrayendo cada carácter del texto a imprimir se puede hacer!
Saludos, y por falta de tiempo no puedo hacer un demo

Re: Como imprimir textos con orientacion diferente
Hola
Prueba lo siguiente... ( Texto Vertical )
--------------------
Try this ... ( Vertical Text )
Prueba lo siguiente... ( Texto Vertical )
--------------------
Try this ... ( Vertical Text )
Code: Select all
FUNCTION Imprime()
LOCAL cText := "T h i s i s a T e x t "
SELECT PRINTER DIALOG TO lSuccess PREVIEW
IF lSuccess == .T.
START PRINTDOC
START PRINTPAGE
@ 050,010 PRINT cText TO 100,014 FONT "Courier New" SIZE 9
@ 105,010 PRINT cText FONT "Courier New" SIZE 9
END PRINTPAGE
END PRINTDOC
ENDIF
RETURN nil
Andrés González López
Desde Guadalajara, Jalisco. México.
Desde Guadalajara, Jalisco. México.
Re: Como imprimir textos con orientacion diferente
PRINT posee una propiedad que se llama ANGLE, Ejemplo:jucar_es wrote:Buen dia a todos
alguien sabe como puedo imprimir un en dos orientaciones DIFente orientacion
T
E
X
T
O
---texto
GRACIAS
@ 47,11 PRINT "Precio Venta Público recomendado: "+Mil(WinPedDat.T_TotalPed.Value+nPorcentaje,9,2)+ " €" ;
FONT "Arial" ;
SIZE 16 COLOR GRAY ANGLE -90
Lo imprime en vertical.
HPDFPRINT tambien lo tiene implementado...en HMG, aunque en Minigui Extended aun no lo está
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
Como imprimir textos con orientacion diferente
Me parece que en HMG no existe esta propiedad. Lo que vi es que está presente es para HPDFPRINT ARC RADIUS. Estás seguro que en HMG se puede imprimir como dices ?JALMAG wrote:PRINT posee una propiedad que se llama ANGLE, Ejemplo:
@ 47,11 PRINT "Precio Venta Público recomendado: "+Mil(WinPedDat.T_TotalPed.Value+nPorcentaje,9,2)+ " €" ;
FONT "Arial" ;
SIZE 16 COLOR GRAY ANGLE -90
Lo imprime en vertical.
HPDFPRINT tambien lo tiene implementado...en HMG
En Minigui Extended, en el ejemplo C:\minigui\SAMPLES\BASIC\MiniPrint existe la propiedad ANGLE como dices. Pero en HMG me parece que no.

En HMG, no existe los parametros lAngle y nAngle como los tiene en Minigui Extended. Eso porque la funcion _HMG_PRINTER_C_PRINT en C no está presente.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
Re: Como imprimir textos con orientacion diferente
Pablo César wrote:Me parece que en HMG no existe esta propiedad. Lo que vi es que está presente es para HPDFPRINT ARC RADIUS. Estás seguro que en HMG se puede imprimir como dices ?JALMAG wrote:PRINT posee una propiedad que se llama ANGLE, Ejemplo:
@ 47,11 PRINT "Precio Venta Público recomendado: "+Mil(WinPedDat.T_TotalPed.Value+nPorcentaje,9,2)+ " €" ;
FONT "Arial" ;
SIZE 16 COLOR GRAY ANGLE -90
Lo imprime en vertical.
HPDFPRINT tambien lo tiene implementado...en HMG
En Minigui Extended, en el ejemplo C:\minigui\SAMPLES\BASIC\MiniPrint existe la propiedad ANGLE como dices. Pero en HMG me parece que no.Existe diferencia en la funcion _HMG_PRINTER_H_PRINT (@ ... PRINT) entre HMG y Minigui Extended.
En HMG, no existe los parametros lAngle y nAngle como los tiene en Minigui Extended. Eso porque la funcion _HMG_PRINTER_C_PRINT en C no está presente.
Efectivamente lo utilizo en Minigui Extended, creia que igualmente esta propiedad estaba presente en HMG. No obstante se puede utilizar hmg_hpdf que si dispone de esa propiedad en lazandolo en la compilacion.
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
Como imprimir textos con orientacion diferente
Disculpame, pero sigo no viendo como actualmente puede ser usado en hmg_hpdf. Puedes describir como hacerlo ?JALMAG wrote:No obstante se puede utilizar hmg_hpdf que si dispone de esa propiedad en lazandolo en la compilacion.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein