filters

epsexportdlg.cc

00001 /* This file is part of the KDE project
00002    Copyright (C) 2002, The Karbon Developers
00003 
00004    This library is free software; you can redistribute it and/or
00005    modify it under the terms of the GNU Library General Public
00006    License as published by the Free Software Foundation; either
00007    version 2 of the License, or (at your option) any later version.
00008 
00009    This library is distributed in the hope that it will be useful,
00010    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012    Library General Public License for more details.
00013 
00014    You should have received a copy of the GNU Library General Public License
00015    along with this library; see the file COPYING.LIB.  If not, write to
00016    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00017  * Boston, MA 02110-1301, USA.
00018 */
00019 
00020 #include <qbuttongroup.h>
00021 #include <qradiobutton.h>
00022 #include <qstring.h>
00023 #include <qvbox.h>
00024 #include <qcheckbox.h>
00025 
00026 #include <klocale.h>
00027 #include <knuminput.h>
00028 
00029 #include "epsexportdlg.h"
00030 
00031 
00032 EpsExportDlg::EpsExportDlg( QWidget* parent, const char* name )
00033     : KDialogBase( parent, name, true, i18n( "EPS Export" ), Ok | Cancel )
00034 {
00035     QVBox* page = makeVBoxMainWidget();
00036 
00037     m_psLevelButtons = new QButtonGroup( 1, QGroupBox::Horizontal,
00038         i18n( "Options" ), page );
00039 
00040     QRadioButton* radio;
00041     radio = new QRadioButton( i18n( "PostScript level 1" ), m_psLevelButtons );
00042     radio = new QRadioButton( i18n( "PostScript level 2" ), m_psLevelButtons );
00043     radio = new QRadioButton( i18n( "PostScript level 3" ), m_psLevelButtons );
00044 
00045     m_hiddenExport = new QCheckBox( i18n( "Export hidden layers" ), page );
00046     m_hiddenExport->setChecked( true );
00047 
00048     m_psLevelButtons->setRadioButtonExclusive( true );
00049     m_psLevelButtons->setButton( 2 );
00050 }
00051 
00052 uint
00053 EpsExportDlg::psLevel() const
00054 {
00055     return static_cast<uint>(
00056         m_psLevelButtons->id( m_psLevelButtons->selected() ) );
00057 }
00058 
00059 bool
00060 EpsExportDlg::exportHidden() const
00061 {
00062     return m_hiddenExport->isChecked();
00063 }
00064 #include "epsexportdlg.moc"
00065 
KDE Home | KDE Accessibility Home | Description of Access Keys