|
|||||||
|
|
|
![]() |
|
|
Strumenti |
|
|
#1 |
|
Senior Member
Iscritto dal: Aug 2005
Messaggi: 586
|
[Borland C++] stampa in PDF (e non solo)
Utilizzando la libreria Printers.hpp riesco a stampare delle pagine grafiche ma non con tutte le stampanti
Con alcune funziona: HP 4P, HP 5P, Phaser 8400 (LAN) ma con altre NO Acrobat Distiller, NRG D422 (LAN), NRG D420 (LAN) mi stampa le pagine vuote ! if (PrintDialog1->Execute()) { TRect r=Rect(left,top,right,bottom); Image1->Canvas->CopyMode = cmSrcCopy; Image1->Canvas->CopyRect(r,FormMain->Canvas,r); Image->Canvas->CopyMode = cmNotSrcCopy; Image->Canvas->CopyRect(r,FormMain->Canvas,r); TRect r2 = Rect(100,(int)(Prntr->PageHeight/20),Prntr->PageWidth-100,(int)(Prntr->PageHeight*9/20)); FormMain->Canvas->CopyMode = cmSrcCopy; FormMain->Canvas->CopyRect(r,Image1->Canvas,r); Prntr->BeginDoc(); Prntr->Canvas->CopyRect(r2,Image->Canvas,r); Prntr->EndDoc(); } Qualche idea ? dove sbaglio ? devo aggiungere qualche cosa ?
__________________
Hi-Fi: Brigno Stereo HT: Samsung Plasma 50" 656, Sky HD (Pace), Harmony 885, PS3, Wii, Kit 5.1 Kef 3005, Pioneer VSX-LX1019AH-K e LG BR390 |
|
|
|
|
|
#2 |
|
Senior Member
Iscritto dal: Aug 2005
Messaggi: 586
|
Aiutoooooo
Mi serve qualche dritta
__________________
Hi-Fi: Brigno Stereo HT: Samsung Plasma 50" 656, Sky HD (Pace), Harmony 885, PS3, Wii, Kit 5.1 Kef 3005, Pioneer VSX-LX1019AH-K e LG BR390 |
|
|
|
|
|
#3 |
|
Senior Member
Iscritto dal: Apr 2000
Città: Roma
Messaggi: 15625
|
Provo...ho avuto una esperienza simile parecchi anni fa, col Delphi (usa la stessa VCL del Builder)
Avevo osservato che su alcuni driver (forse anche col Distiller, vatti a ricordare), certi parametri dell'oggetto TPrinter erano 0. Forse proprio PageWidth e PageHeight, che tu usi. Non ho mai capito il motivo, e ora non mi sovviene il workaround che ho usato (forse ho utilizzato le dimensioni della TCanvas nella TPrinter)
__________________
0: or %edi, %ecx; adc %eax, (%edx); popf; je 0b-22; pop %ebx; fadds 0x56(%ecx); lds 0x56(%ebx), %esp; mov %al, %al andeqs pc, r1, #147456; blpl 0xff8dd280; ldrgtb r4, [r6, #-472]; addgt r5, r8, r3, ror #12 |
|
|
|
|
|
#4 |
|
Senior Member
Iscritto dal: Aug 2005
Messaggi: 586
|
Considerando che siamo a fine luglio non posso far altro che ringraziare anticipatamente !!!
__________________
Hi-Fi: Brigno Stereo HT: Samsung Plasma 50" 656, Sky HD (Pace), Harmony 885, PS3, Wii, Kit 5.1 Kef 3005, Pioneer VSX-LX1019AH-K e LG BR390 |
|
|
|
|
|
#5 |
|
Senior Member
Iscritto dal: Aug 2005
Messaggi: 586
|
PageWidth e PageHeight durante il debug hanno valori alti tipo 14xxx e rotti
Cosa intendi per "forse ho utilizzato le dimensioni della TCanvas nella TPrinter" ? Ancora grazie
__________________
Hi-Fi: Brigno Stereo HT: Samsung Plasma 50" 656, Sky HD (Pace), Harmony 885, PS3, Wii, Kit 5.1 Kef 3005, Pioneer VSX-LX1019AH-K e LG BR390 |
|
|
|
|
|
#6 | |
|
Senior Member
Iscritto dal: Apr 2000
Città: Roma
Messaggi: 15625
|
Quote:
Comunque nel mio casob avevo trovato dei valori "vitali" a 0, purtroppo non ricordo quali erano.
__________________
0: or %edi, %ecx; adc %eax, (%edx); popf; je 0b-22; pop %ebx; fadds 0x56(%ecx); lds 0x56(%ebx), %esp; mov %al, %al andeqs pc, r1, #147456; blpl 0xff8dd280; ldrgtb r4, [r6, #-472]; addgt r5, r8, r3, ror #12 |
|
|
|
|
|
| Strumenti | |
|
|
Tutti gli orari sono GMT +1. Ora sono le: 17:21.



















