• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

kig

  • sources
  • kde-4.12
  • kdeedu
  • kig
  • filters
latexexporteroptions.cc
Go to the documentation of this file.
1 // Copyright (C) 2005 Pino Toscano <toscano.pino@tiscali.it>
2 
3 // This program is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU General Public License
5 // as published by the Free Software Foundation; either version 2
6 // of the License, or (at your option) any later version.
7 
8 // This program is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 // GNU General Public License for more details.
12 
13 // You should have received a copy of the GNU General Public License
14 // along with this program; if not, write to the Free Software
15 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
16 // 02110-1301, USA.
17 
18 #include "latexexporteroptions.h"
19 #include "latexexporteroptions.moc"
20 
21 #include "ui_latexexporteroptionswidget.h"
22 
23 #include <qcheckbox.h>
24 #include <qlayout.h>
25 
26 LatexExporterOptions::LatexExporterOptions( QWidget* parent )
27  : QWidget( parent )
28 {
29  expwidget = new Ui_LatexExporterOptionsWidget();
30  expwidget->setupUi( this );
31 
32  layout()->setMargin( 0 );
33 }
34 
35 LatexExporterOptions::~LatexExporterOptions()
36 {
37  delete expwidget;
38 }
39 
40 void LatexExporterOptions::setFormat(LatexExporterOptions::LatexOutputFormat format)
41 {
42  switch (format)
43  {
44  case PSTricks:
45  expwidget->psTricksRadioButton->setChecked(true);
46  break;
47  case TikZ:
48  expwidget->tikzRadioButton->setChecked(true);
49  break;
50  case Asymptote:
51  expwidget->asyRadioButton->setChecked(true);
52  break;
53  // This enum member is just to track the number of formats, nothing to do here
54  case FormatCount:
55  break;
56  }
57 }
58 
59 LatexExporterOptions::LatexOutputFormat LatexExporterOptions::format()
60 {
61  if (expwidget->psTricksRadioButton->isChecked())
62  {
63  return PSTricks;
64  }
65  else if (expwidget->tikzRadioButton->isChecked())
66  {
67  return TikZ;
68  }
69  else
70  {
71  return Asymptote;
72  }
73 }
74 
75 void LatexExporterOptions::setStandalone(bool standalone)
76 {
77  if (standalone)
78  {
79  expwidget->documentRadioButton->setChecked(true);
80  }
81  else
82  {
83  expwidget->pictureRadioButton->setChecked(true);
84  }
85 }
86 
87 bool LatexExporterOptions::standalone()
88 {
89  return expwidget->documentRadioButton->isChecked();
90 }
91 
92 void LatexExporterOptions::setGrid( bool grid )
93 {
94  expwidget->showGridCheckBox->setChecked( grid );
95 }
96 
97 bool LatexExporterOptions::showGrid() const
98 {
99  return expwidget->showGridCheckBox->isChecked();
100 }
101 
102 void LatexExporterOptions::setAxes( bool axes )
103 {
104  expwidget->showAxesCheckBox->setChecked( axes );
105 }
106 
107 bool LatexExporterOptions::showAxes() const
108 {
109  return expwidget->showAxesCheckBox->isChecked();
110 }
111 
112 void LatexExporterOptions::setExtraFrame( bool frame )
113 {
114  expwidget->showFrameCheckBox->setChecked( frame );
115 }
116 
117 bool LatexExporterOptions::showExtraFrame() const
118 {
119  return expwidget->showFrameCheckBox->isChecked();
120 }
LatexExporterOptions::setExtraFrame
void setExtraFrame(bool frame)
Definition: latexexporteroptions.cc:112
LatexExporterOptions::PSTricks
Definition: latexexporteroptions.h:36
QWidget
LatexExporterOptions::~LatexExporterOptions
~LatexExporterOptions()
Definition: latexexporteroptions.cc:35
LatexExporterOptions::FormatCount
Definition: latexexporteroptions.h:39
LatexExporterOptions::setGrid
void setGrid(bool grid)
Definition: latexexporteroptions.cc:92
LatexExporterOptions::LatexOutputFormat
LatexOutputFormat
Definition: latexexporteroptions.h:34
LatexExporterOptions::setFormat
void setFormat(LatexOutputFormat format)
Definition: latexexporteroptions.cc:40
LatexExporterOptions::showAxes
bool showAxes() const
Definition: latexexporteroptions.cc:107
latexexporteroptions.h
LatexExporterOptions::format
LatexOutputFormat format()
Definition: latexexporteroptions.cc:59
LatexExporterOptions::setStandalone
void setStandalone(bool standalone)
Definition: latexexporteroptions.cc:75
LatexExporterOptions::Asymptote
Definition: latexexporteroptions.h:38
LatexExporterOptions::LatexExporterOptions
LatexExporterOptions(QWidget *parent)
Definition: latexexporteroptions.cc:26
LatexExporterOptions::standalone
bool standalone()
Definition: latexexporteroptions.cc:87
LatexExporterOptions::setAxes
void setAxes(bool axes)
Definition: latexexporteroptions.cc:102
LatexExporterOptions::TikZ
Definition: latexexporteroptions.h:37
LatexExporterOptions::showExtraFrame
bool showExtraFrame() const
Definition: latexexporteroptions.cc:117
LatexExporterOptions::showGrid
bool showGrid() const
Definition: latexexporteroptions.cc:97
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:35:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kig

Skip menu "kig"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal