English
Forum

three RTF print out

 
- Page 1 -



Thomas
Freier
any Eigenversuche hit[ed] fehl. has of/ one a suggestion, How two RTFs fester Size and a Dritte discretionary long ausgedruckt go can.
Analog one Example of Uwe 'Pascal' becomes here only a Page printed. but How geht's moreover?
CompileMarkSeparation
 $H Windows.ph
 $H RichEdit.ph
 $U RTFHandling.pcu = R_'RTF-PCU einbinden
 $U objects.pcu = R_

proc DrawRichText2'---------------------------------------------------------DrawRichText2

    parameters RTF&,PosX%,PosY%,MaxX%,MaxY%'--Position + Grösse in Pixeln!
    declare PrinterDpiX%,PrinterDpiY%
    declare WindowDpiX%,WindowDpiY%
    declare fx!,fy!

    if %printing'--Bei Druck: %HDC2 = %HDC = &PDC

        ~SetMapMode(%hdc2,1)
        ~SetWindowExtEx(%hdc2,1,1,0)
        ~SetViewPortExtEx(%hdc2,1,1,0)
        PosX%=PosX%+30'--Korrektur ???
        PosY%=PosY%+30'--Korrektur ???

    endif

    PrinterDpiX%=~GetDeviceCaps(%hdc2,~LOGPIXELSX)'--dpi X des Druckers
    PrinterDpiY%=~GetDeviceCaps(%hdc2,~LOGPIXELSY)'--dpi X des Druckers
    WindowDpiX%=~GetDeviceCaps(~GetDC(%hwnd),~LOGPIXELSX)'--dpi X des Bildschirms (!)
    WindowDpiY%=~GetDeviceCaps(~GetDC(%hwnd),~LOGPIXELSY)'--dpi Y des Bildschirms (!)
    PosX%=int(PosX%/WindowDpiX%*1440)
    PosY%=int(PosY%/WindowDpiX%*1440)
    MaxX%=int(MaxX%/WindowDpiX%*1440)
    MaxY%=int(MaxY%/WindowDpiX%*1440)
    declare Range#
    dim Range#,48
    clear Range#
    long Range#, 0=%hdc2,%hdc2
    long Range#, 8=PosX%,PosY%,PosX%+MaxX%,PosY%+MaxY%
    long Range#,24=PosX%,PosY%,PosX%+MaxX%,PosY%+MaxY%
    long Range#,44=-1
    sendmessage(RTF&,~EM_FORMATRANGE,1,Range#)

    if %printing

        fx!=~GetDeviceCaps(%hdc2,~LOGPIXELSX)/300
        fy!=~GetDeviceCaps(%hdc2,~LOGPIXELSY)/300
        ~SetMapMode(%hdc2,~MM_ANISOTROPIC)
        ~SetWindowExtEx(%hdc2,6400,9600,0)
        ~SetViewPortExtEx(%hdc2,int(2200*fx!),int(3300*fy!),0)

    endif

    dispose Range#
    casenot %printing:repaint

endproc'---------------------------------------------------------------------------------

window 0,0-%maxX,800
var rtf_dll& =  R_INTITFORCREATERTF()'DLL laden mit PCU
var _RichEdit& = R_CREATERICHEDIT(%hwnd,"",70,0,350,100,9000)' Richedit erstellen mit PCU
RTF("LoadRTF",_RichEdit&,"Bootsplatz.rtf")
var __RichEdit& = R_CREATERICHEDIT(%hwnd,"",480,0,280,100,9000)' Richedit erstellen mit PCU
RTF("LoadRTF",__RichEdit&,"Label 105x42.rtf")
var RichEdit& = R_CREATERICHEDIT(%hwnd,"",0,102,800,400,9000)' Richedit erstellen mit PCU
var rtf_hdc& = R_PREPAREFORLINEBREAK(RichEdit&)' Device Context erzeugen mit PCU
R_Init_object(RichEdit&)'Zum Bildempfang vorbereiten
RTF("LoadRTF",RichEdit&,"Bilder-Album.rtf")
startprint "*xx"
DrawRichText2 _RichEdit&,80,10,400,150
DrawRichText2 __RichEdit&,500,10,250,150
DrawRichText2 RichEdit&,0,150,800,14900
endprint
waitkey
R_DEINITRTF(RichEdit&,rtf_hdc&,rtf_dll&)'RTF-Aufräumen
R_DEINITRTF(_RichEdit&,rtf_hdc&,rtf_dll&)
R_DEINITRTF(__RichEdit&,rtf_hdc&,rtf_dll&)
R_DeInit_object()'RTF-Aufräumen<
End

remainder in the zipper.

394 kB
Hochgeladen:10/12/10
Downloadcounter89
Download
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/12/10  
 



« this Posting watts as Solution marked. »


Uwe
''Pascal''
Niemeier
Hi Thomas!

means is "RTF in RTF by OLE" für's Print out already time OK?
and it fails on it, that the eingebetteten RTFs (The together Yes so 'ne manner Briefkopf form) not machine go can, if no Word present is?

have with the the Print time getestet; though only MS Image Writer, because I momentarily none "echten" printer available have. sees exakt so from How by Wordpad ausgedruckt. ought to means useable his. See attachment.

with the Edit without Word: time see...

another word to the code at the beginning this Threads: The watts original develops, for a Image during the Druckens into document without OLE-Support einzublenden. therefore find itself therein different APIs to Größenanpassung, The to that Print reiner documents (with OLE) not necessary are (hope I at least).

SeeYou
Pascal

346 kB
Version:1
Kurzbeschreibung: Print RTF
Hochgeladen:10/15/10
Downloadcounter71
Download
 
10/15/10  
 



Hello Thomas,

functions The Solution from this Thread [...]  with you circa a complete RTF to print and helps you these?
 
10/12/10  
 




Thomas
Freier
Hello iF,

in the momentum not. Manipulationen for may part were erfolglos and What is with meant: "hilft you these?" .
too with the Solution from the Thread be I not yet happy. by me are to the pressure The Lines zerstückelt.

106 kB
Hochgeladen:10/12/10
Downloadcounter79
Download
70 kB
Hochgeladen:10/12/10
Downloadcounter81
Download
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/12/10  
 



Image print-end.jpg shows well the a To little wide staid is - thatswhy Better get going everything so to left gefercht.

Perhaps. should we first the pure normal simple RTF-Print out "sauber" and "überall" hinbekommen and hereon aufbauend then such Specials as here in the Thread treat.

i'd say back to the middle-aged Thread if the program there not does what it should and then vlt. hereon set up.

your obigen code can I me first today evening correctly. standing and testing.
 
10/12/10  
 




Thomas
Freier
Yes, see so did i so. These Umbrüche are but too with the Text99.
strange but too, if The File before the pressure stored and thereafter anew loaded becomes, stay The Changes consist are but so not in the gespeicherten File.
The attempt The gespeicherte File to that pressure into To this tack erstelltes
CompileMarkSeparation
_RichEdit& = R_CREATERICHEDIT(%hwnd,"",0,0,0,0,9000)' Richedit erstellen mit PCU
_rtf_hdc& = R_PREPAREFORLINEBREAK(RichEdit&)' Device Context erzeugen mit PCU
R_Init_object(_RichEdit&)'Zum Bildempfang vorbereitenre>
To lay, end always with Schutzverletzung (RTF.pcu). time see How I the behebe.
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/12/10  
 



OK understand, too ifs ichs not yet überschaue. ^^
 
10/12/10  
 



Druckt this code because at least The first Page half-way correctly?
CompileMarkSeparation
'{$cleq}
'{$pushkeyword R_*}
 $H Windows.ph
 $H RichEdit.ph
 $U RTFHandling.pcu = R_'RTF-PCU einbinden
 $U objects.pcu = R_

proc DrawRichText2'---------------------------------------------------------DrawRichText2

    parameters RTF&,PosX%,PosY%,MaxX%,MaxY%'--Position + Grösse in Pixeln!
    declare PrinterDpiX%,PrinterDpiY%
    declare WindowDpiX%,WindowDpiY%
    declare fx!,fy!

    if %printing'--Bei Druck: %HDC2 = %HDC = &PDC

        ~SetMapMode(%hdc2,1)
        ~SetWindowExtEx(%hdc2,1,1,0)
        ~SetViewPortExtEx(%hdc2,1,1,0)

    endif

    PrinterDpiX%=~GetDeviceCaps(%hdc2,~LOGPIXELSX)'--dpi X des Druckers
    PrinterDpiY%=~GetDeviceCaps(%hdc2,~LOGPIXELSY)'--dpi X des Druckers
    WindowDpiX%=~GetDeviceCaps(~GetDC(%hwnd),~LOGPIXELSX)'--dpi X des Bildschirms (!)
    WindowDpiY%=~GetDeviceCaps(~GetDC(%hwnd),~LOGPIXELSY)'--dpi Y des Bildschirms (!)
    PosX%=int(PosX%/WindowDpiX%*1440)
    PosY%=int(PosY%/WindowDpiX%*1440)
    MaxX%=int(MaxX%/WindowDpiX%*1440)
    MaxY%=int(MaxY%/WindowDpiX%*1440)
    declare Range#
    dim Range#,48
    clear Range#
    long Range#, 0=%hdc2,%hdc2
    long Range#, 8=PosX%,PosY%,PosX%+MaxX%,PosY%+MaxY%
    long Range#,24=PosX%,PosY%,PosX%+MaxX%,PosY%+MaxY%
    long Range#,44=-1
    sendmessage(RTF&,~EM_FORMATRANGE,1,Range#)

    if %printing

        fx!=~GetDeviceCaps(%hdc2,~LOGPIXELSX)/300
        fy!=~GetDeviceCaps(%hdc2,~LOGPIXELSY)/300
        ~SetMapMode(%hdc2,~MM_ANISOTROPIC)
        ~SetWindowExtEx(%hdc2,6400,9600,0)
        ~SetViewPortExtEx(%hdc2,int(2200*fx!),int(3300*fy!),0)

    endif

    dispose Range#
    casenot %printing:repaint

endproc'---------------------------------------------------------------------------------

window 0,0-%maxx,%maxy
var rtf_dll& =  R_INTITFORCREATERTF()'DLL laden mit PCU
var _RichEdit& = R_CREATERICHEDIT(%hwnd,"",10000,0,350,100,9000)' Richedit erstellen mit PCU
RTF("LoadRTF",_RichEdit&,"Bootsplatz.rtf")
var __RichEdit& = R_CREATERICHEDIT(%hwnd,"",10000,0,280,100,9000)' Richedit erstellen mit PCU
RTF("LoadRTF",__RichEdit&,"Label 105x42.rtf")
var RichEdit& = R_CREATERICHEDIT(%hwnd,"",10000,102,800,400,9000)' Richedit erstellen mit PCU
var rtf_hdc& = R_PREPAREFORLINEBREAK(RichEdit&)' Device Context erzeugen mit PCU
R_Init_object(RichEdit&)'Zum Bildempfang vorbereiten
RTF("LoadRTF",RichEdit&,"Bilder-Album.rtf")
startprint "*xx"
DrawRichText2 _RichEdit&,70,0,350,100
DrawRichText2 __RichEdit&,480,0,280,100
DrawRichText2 RichEdit&,70,100,640,960
endprint
waitinput
external("kernel32","ExitProcess",0)
R_DEINITRTF(RichEdit&,rtf_hdc&,rtf_dll&)'RTF-Aufräumen
R_DEINITRTF(_RichEdit&,rtf_hdc&,rtf_dll&)
R_DEINITRTF(__RichEdit&,rtf_hdc&,rtf_dll&)
R_DeInit_object()'RTF-Aufräumen
> End

123 kB
Hochgeladen:10/12/10
Downloadcounter142
Download
 
10/12/10  
 




Thomas
Freier
Yes, a A4 Page.
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/13/10  
 



Juhu very, means works still Schonmal 3 RTFs...

remaining only spare from the Images-RTF ex 2. Page To print?!
 
10/13/10  
 




Thomas
Freier
Yes very.
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/13/10  
 



too again whom 2 RTF's in the head or ex 2. Page without?
 
10/13/10  
 




Thomas
Freier
Folgeseiten without 1. and 2. RTF.
background is, if MS Word on the System is, can man further RTFs into master-RTF einbetten and too Edit and then too everything print. in the others drop should I The three RTFs separated print without, that to pressure the 1. and 2. RTF one Seitenvorschub results.
 
Gruß Thomas
Windows XP SP2, XProfan X2
10/13/10  
 




Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

10.349 Views

Untitledvor 0 min.
Sven Bader11/18/23
Alibre01/03/20
kustg05/14/19
GDL01/04/16
More...

Themeninformationen



Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie