[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: koffice/kspread/dialogs
From: Anne-Marie Mahfouf <annma () kde ! org>
Date: 2005-11-30 18:16:49
Message-ID: 1133374609.464521.19516.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 484420 by annma:
replace hard code with designer .ui file for Cell Protection tab in Cell Format \
dialog add QWhatsThis help in new .ui dialog
M +2 -1 Makefile.am
M +1 -32 kspread_dlg_layout.cc
M +2 -6 kspread_dlg_layout.h
A protection_cell_format.ui
--- trunk/koffice/kspread/dialogs/Makefile.am #484419:484420
@@ -44,7 +44,8 @@
sheet_properties.cc \
kspread_dlg_find.cc \
position_cell_format.ui \
- font_cell_format.ui
+ font_cell_format.ui \
+ protection_cell_format.ui
noinst_HEADERS = \
kspread_dlg_angle.h \
--- trunk/koffice/kspread/dialogs/kspread_dlg_layout.cc #484419:484420
@@ -2050,40 +2050,9 @@
}
CellFormatPageProtection::CellFormatPageProtection( QWidget* parent, \
CellFormatDialog * _dlg )
- : QWidget( parent ),
+ : ProtectionTab( parent ),
m_dlg( _dlg )
{
- QVBoxLayout * Form1Layout = new QVBoxLayout( this, KDialog::marginHint(), \
KDialog::spacingHint(), "Form1Layout");
-
- QGroupBox * groupBox1 = new QGroupBox( 0, Qt::Vertical, i18n( "Protection" \
), this, "groupBox1" );
- groupBox1->layout()->setSpacing( KDialog::spacingHint() );
- groupBox1->layout()->setMargin( KDialog::marginHint() );
- QVBoxLayout * groupBox1Layout = new QVBoxLayout( groupBox1->layout() );
-
- m_bIsProtected = new QCheckBox( i18n( "&Protected" ), groupBox1, "m_bIsProtected" \
);
- QWhatsThis::add(m_bIsProtected, i18n( "If checked, the cell content will be \
protected. This is the default behaviour. You need to protect the whole sheet using \
theTools->Protect document->Protect Sheet... menu for this to work. " \
) );
- m_bIsProtected->setChecked( true );
- groupBox1Layout->addWidget( m_bIsProtected );
-
- m_bHideFormula = new QCheckBox( i18n( "&Hide formula" ), groupBox1, \
"m_bHideFormula" );
- groupBox1Layout->addWidget( m_bHideFormula );
-
- m_bHideAll = new QCheckBox( i18n( "Hide &all" ), groupBox1, "m_bHideAll" );
- groupBox1Layout->addWidget( m_bHideAll );
- Form1Layout->addWidget( groupBox1 );
-
- QGroupBox * groupBox2 = new QGroupBox( 0, Qt::Vertical, i18n( "Printing" \
), this, "groupBox2" );
- groupBox2->layout()->setSpacing( KDialog::spacingHint() );
- groupBox2->layout()->setMargin( KDialog::marginHint() );
- QVBoxLayout * groupBox2Layout = new QVBoxLayout( groupBox2->layout() );
-
- m_bDontPrint = new QCheckBox( i18n( "&Do not print text" ), groupBox2, \
"m_bDontPrint" );
- QWhatsThis::add(m_bDontPrint, i18n( "If checked, the content of the cell will not \
be printed. If this is not checked (default), the cell content will be printed.\nNote \
that you can print it even if the cell is protected." ) );
- groupBox2Layout->addWidget( m_bDontPrint );
- Form1Layout->addWidget( groupBox2 );
- QSpacerItem * spacer_4 = new QSpacerItem( 20, 90, QSizePolicy::Minimum, \
QSizePolicy::Expanding );
- Form1Layout->addItem( spacer_4 );
-
m_bDontPrint->setChecked( m_dlg->bDontPrintText );
m_bHideAll->setChecked( m_dlg->bHideAll );
m_bHideFormula->setChecked( m_dlg->bHideFormula );
--- trunk/koffice/kspread/dialogs/kspread_dlg_layout.h #484419:484420
@@ -43,6 +43,7 @@
#include "kspread_value.h"
#include "position_cell_format.h"
#include "font_cell_format.h"
+#include "protection_cell_format.h"
#include <qpushbutton.h>
#include <qcheckbox.h>
@@ -485,7 +486,7 @@
CellFormatDialog *dlg;
};
-class CellFormatPageProtection : public QWidget
+class CellFormatPageProtection : public ProtectionTab
{
Q_OBJECT
@@ -500,11 +501,6 @@
void applyFormat( Format * _obj );
protected:
- QCheckBox * m_bIsProtected;
- QCheckBox * m_bHideFormula;
- QCheckBox * m_bHideAll;
- QCheckBox * m_bDontPrint;
-
CellFormatDialog * m_dlg;
bool m_isProtected;
bool m_hideFormula;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic