Patch level : 10.0
Files correlati : aprintbar.h Ricompilazione Demo : [ ] Commento : Aggiunta barra di stampa avanzata git-svn-id: svn://10.65.10.50/trunk@18608 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
aae3e6c958
commit
70a2cdd421
19
include/aprintbar.h
Executable file
19
include/aprintbar.h
Executable file
@ -0,0 +1,19 @@
|
|||||||
|
BUTTON DLG_PRINT 2 2
|
||||||
|
BEGIN
|
||||||
|
PROMPT 1 1 "Stampa"
|
||||||
|
PICTURE TOOL_PRINT
|
||||||
|
END
|
||||||
|
|
||||||
|
BUTTON DLG_SETPRINT 2 2
|
||||||
|
BEGIN
|
||||||
|
PROMPT 2 1 "Imposta"
|
||||||
|
PICTURE TOOL_SETPRINT
|
||||||
|
END
|
||||||
|
|
||||||
|
BUTTON DLG_PREVIEW 2 2
|
||||||
|
BEGIN
|
||||||
|
PROMPT 3 1 "~Anteprima"
|
||||||
|
PICTURE TOOL_PREVIEW
|
||||||
|
END
|
||||||
|
|
||||||
|
#include <helpbar.h>
|
@ -1649,6 +1649,8 @@ bool TBook::init()
|
|||||||
{
|
{
|
||||||
int size;
|
int size;
|
||||||
_rcd = xvt_print_create_by_name(&size, XVT_PDF_PRINTER_NAME);
|
_rcd = xvt_print_create_by_name(&size, XVT_PDF_PRINTER_NAME);
|
||||||
|
if (_pw > _ph) // width > height -> landscape
|
||||||
|
xvt_app_escape (XVT_ESC_SET_PRINTER_INFO, _rcd, &_ph, &_pw, &_pvr, &_phr); //
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
_rcd = printer().get_printrcd();
|
_rcd = printer().get_printrcd();
|
||||||
@ -1671,7 +1673,7 @@ bool TBook::init()
|
|||||||
delete _printwin;
|
delete _printwin;
|
||||||
_printwin = new TWindow_printer(_rcd, _pdf_file);
|
_printwin = new TWindow_printer(_rcd, _pdf_file);
|
||||||
|
|
||||||
return true;
|
return _printwin->win() != NULL_WIN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1858,20 +1860,17 @@ bool TBook::split_file_if_needed()
|
|||||||
|
|
||||||
bool TBook::main_loop()
|
bool TBook::main_loop()
|
||||||
{
|
{
|
||||||
_print_aborted = true;
|
_print_aborted = !init();
|
||||||
if (!init())
|
|
||||||
return false;
|
|
||||||
|
|
||||||
|
if (!_print_aborted)
|
||||||
|
{
|
||||||
if (_pageto < _pagefrom)
|
if (_pageto < _pagefrom)
|
||||||
_pageto = pages();
|
_pageto = pages();
|
||||||
|
|
||||||
_print_aborted = false;
|
|
||||||
for (word copy = 0; copy < _copies && !_print_aborted; copy++)
|
for (word copy = 0; copy < _copies && !_print_aborted; copy++)
|
||||||
{
|
{
|
||||||
for (size_t page = _pagefrom; page <= _pageto && !_print_aborted; page++)
|
for (size_t page = _pagefrom; page <= _pageto && !_print_aborted; page++)
|
||||||
{
|
_print_aborted = !print_page(*_printwin, page);
|
||||||
if (!print_page( *_printwin, page))
|
|
||||||
_print_aborted = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user