The DiagramPrintDialog class This class implements both the dialog allowing users to configure the printing of a project file and the printing itself.
More...
#include <diagramprintdialog.h>
Inherits QWidget.
The DiagramPrintDialog class This class implements both the dialog allowing users to configure the printing of a project file and the printing itself.
◆ DiagramPrintDialog() [1/2]
| DiagramPrintDialog::DiagramPrintDialog |
( |
QETProject * |
project, |
|
|
QWidget * |
parent = nullptr |
|
) |
| |
Constructeur
- Parameters
-
| project | Schema a imprimer |
| parent | Widget parent du dialogue |
◆ ~DiagramPrintDialog()
| DiagramPrintDialog::~DiagramPrintDialog |
( |
| ) |
|
|
override |
◆ DiagramPrintDialog() [2/2]
◆ acceptPrintTypeDialog
| void DiagramPrintDialog::acceptPrintTypeDialog |
( |
| ) |
|
|
privateslot |
Verifie l'etat du dialogue permettant le choix du type d'impression lorsque l'utilisateur le valide.
- Todo:
◆ browseFilePrintTypeDialog
| void DiagramPrintDialog::browseFilePrintTypeDialog |
( |
| ) |
|
|
privateslot |
Permet a l'utilisateur de choisir un fichier
◆ buildDialog()
| void DiagramPrintDialog::buildDialog |
( |
| ) |
|
|
private |
◆ buildPrintTypeDialog()
| void DiagramPrintDialog::buildPrintTypeDialog |
( |
| ) |
|
|
private |
Construit un dialogue non standard pour demander a l'utilisateur quelle type d'impression il souhaite effectuer : PDF, PS ou imprimante physique
◆ diagramRect()
◆ docName()
| QString DiagramPrintDialog::docName |
( |
| ) |
const |
- Returns
- le nom du document
◆ exec()
| void DiagramPrintDialog::exec |
( |
| ) |
|
Execute le dialogue d'impression
◆ fileName()
| QString DiagramPrintDialog::fileName |
( |
| ) |
const |
◆ horizontalPagesCount()
| int DiagramPrintDialog::horizontalPagesCount |
( |
Diagram * |
diagram, |
|
|
const ExportProperties & |
options, |
|
|
bool |
fullpage = false |
|
) |
| const |
- Parameters
-
| diagram | Schema a imprimer |
| options | Rendering options |
| fullpage | true pour utiliser toute la feuille dans le calcul |
- Returns
- La largeur du "poster" en nombre de pages pour imprimer le schema avec l'orientation et le format papier utilise dans l'imprimante en cours.
◆ loadPageSetupForCurrentPrinter()
| void DiagramPrintDialog::loadPageSetupForCurrentPrinter |
( |
| ) |
|
|
private |
Load parameters previously set in the "page setup" dialog for the current printer, if any.
◆ pagesCount()
| int DiagramPrintDialog::pagesCount |
( |
Diagram * |
diagram, |
|
|
const ExportProperties & |
options, |
|
|
bool |
fullpage = false |
|
) |
| const |
- Parameters
-
| diagram | Schema a imprimer |
| options | Rendering options |
| fullpage | true pour utiliser toute la feuille dans le calcul |
- Returns
- Le nombre de pages necessaires pour imprimer le schema avec l'orientation et le format papier utilise dans l'imprimante en cours.
◆ print
| void DiagramPrintDialog::print |
( |
const QList< Diagram * > & |
diagrams, |
|
|
bool |
fit_page, |
|
|
const ExportProperties & |
options |
|
) |
| |
|
privateslot |
Effectue l'impression elle-meme
- Parameters
-
| diagrams | Schemas a imprimer |
| fit_page | Booleen indiquant s'il faut adapter les schemas aux pages ou non |
| options | Options de rendu |
◆ printDiagram
| void DiagramPrintDialog::printDiagram |
( |
Diagram * |
diagram, |
|
|
bool |
fit_page, |
|
|
const ExportProperties & |
options, |
|
|
QPainter * |
qp, |
|
|
QPrinter * |
printer = nullptr |
|
) |
| |
|
privateslot |
Imprime un schema
- Parameters
-
| diagram | Schema a imprimer |
| fit_page | True pour adapter les schemas aux pages, false sinon |
| options | Options de rendu a appliquer pour l'impression |
| qp | QPainter a utiliser (deja initialise sur printer) |
| printer | Imprimante a utiliser |
◆ savePageSetupForCurrentPrinter()
| void DiagramPrintDialog::savePageSetupForCurrentPrinter |
( |
| ) |
|
|
private |
Save parameters set in the "page setup" dialog into the QElectroTech configuration. Key/values pairs are associated to the printer for which they have been set.
◆ saveReloadDiagramParameters()
| void DiagramPrintDialog::saveReloadDiagramParameters |
( |
Diagram * |
diagram, |
|
|
const ExportProperties & |
options, |
|
|
bool |
save |
|
) |
| |
|
private |
Sauve ou restaure les parametres du schema
- Parameters
-
| diagram | Schema dont on sauve ou restaure les parametres |
| options | Parametres a appliquer |
| save | true pour memoriser les parametres du schema et appliquer ceux definis dans options, false pour restaurer les parametres |
◆ setDocName()
| void DiagramPrintDialog::setDocName |
( |
const QString & |
name | ) |
|
Definit le nom du document
◆ setFileName()
| void DiagramPrintDialog::setFileName |
( |
const QString & |
name | ) |
|
Definit le nom du PDF si l'utilisateur choisit une sortie vers un PDF
◆ settingsSectionName()
| QString DiagramPrintDialog::settingsSectionName |
( |
const QPrinter * |
printer | ) |
|
|
private |
- Returns
- a section name for use with QSettings in order to store parameters related to printer.
◆ updatePrintTypeDialog
| void DiagramPrintDialog::updatePrintTypeDialog |
( |
| ) |
|
|
privateslot |
Assure la coherence du dialogue permettant le choix du type d'impression
◆ verticalPagesCount()
| int DiagramPrintDialog::verticalPagesCount |
( |
Diagram * |
diagram, |
|
|
const ExportProperties & |
options, |
|
|
bool |
fullpage = false |
|
) |
| const |
- Parameters
-
| diagram | Schema a imprimer |
| options | Rendering options |
| fullpage | true pour utiliser toute la feuille dans le calcul |
- Returns
- La largeur du "poster" en nombre de pages pour imprimer le schema avec l'orientation et le format papier utilise dans l'imprimante en cours.
◆ backup_diagram_background_color
| QColor DiagramPrintDialog::backup_diagram_background_color |
|
private |
◆ browse_button_
| QPushButton* DiagramPrintDialog::browse_button_ |
|
private |
◆ buttons_
| QDialogButtonBox* DiagramPrintDialog::buttons_ |
|
private |
◆ dialog_
| QDialog* DiagramPrintDialog::dialog_ |
|
private |
◆ doc_name_
| QString DiagramPrintDialog::doc_name_ |
|
private |
◆ file_name_
| QString DiagramPrintDialog::file_name_ |
|
private |
◆ filepath_field_
| QLineEdit* DiagramPrintDialog::filepath_field_ |
|
private |
◆ glayout0_
| QGridLayout* DiagramPrintDialog::glayout0_ |
|
private |
◆ hlayout0_
| QHBoxLayout* DiagramPrintDialog::hlayout0_ |
|
private |
◆ pdf_choice_
| QRadioButton* DiagramPrintDialog::pdf_choice_ |
|
private |
◆ pdf_icon_
| QLabel* DiagramPrintDialog::pdf_icon_ |
|
private |
◆ printer_
| QPrinter* DiagramPrintDialog::printer_ |
|
private |
◆ printer_choice_
| QRadioButton* DiagramPrintDialog::printer_choice_ |
|
private |
◆ printer_icon_
| QLabel* DiagramPrintDialog::printer_icon_ |
|
private |
◆ printtype_choice_
| QButtonGroup* DiagramPrintDialog::printtype_choice_ |
|
private |
◆ printtype_label_
| QLabel* DiagramPrintDialog::printtype_label_ |
|
private |
◆ project_
◆ vlayout0_
| QVBoxLayout* DiagramPrintDialog::vlayout0_ |
|
private |
The documentation for this class was generated from the following files: