visual layout fixes for MacOS X

git-svn-id: https://svn.code.sf.net/p/keepassx/code/trunk@132 b624d157-de02-0410-bad0-e51aec6abb33
master
tarek_saidi 18 years ago
parent adea668ad9
commit 9b25cc235d
  1. 2
      src/dialogs/CollectEntropyDlg.cpp
  2. 5
      src/dialogs/PasswordGenDlg.cpp
  3. 24
      src/forms/CollectEntropyDlg.ui
  4. 128
      src/forms/PasswordGenDlg.ui
  5. 1
      src/mainwindow.cpp

@ -26,6 +26,8 @@
CollectEntropyDlg::CollectEntropyDlg(QWidget* parent):QDialog(parent){ CollectEntropyDlg::CollectEntropyDlg(QWidget* parent):QDialog(parent){
setupUi(this); setupUi(this);
setMinimumSize(size());
setMaximumSize(size());
createBanner(&BannerPixmap,getPixmap("dice"),tr("Entropy Collection"),width()); createBanner(&BannerPixmap,getPixmap("dice"),tr("Entropy Collection"),width());
KeyEntropyBuffer=new unsigned char[105]; KeyEntropyBuffer=new unsigned char[105];
MouseEntropyBuffer=new quint16[210]; MouseEntropyBuffer=new quint16[210];

@ -37,8 +37,9 @@ CGenPwDialog::CGenPwDialog(QWidget* parent, bool StandAloneMode,Qt::WFlags fl)
: QDialog(parent,fl) : QDialog(parent,fl)
{ {
setupUi(this); setupUi(this);
createBanner(&BannerPixmap,getPixmap("dice"),tr("Password Generator"),width()); setMinimumSize(size());
setMaximumSize(size());
createBanner(&BannerPixmap,getPixmap("dice"),tr("Password Generator"),width());
connect(ButtonGenerate,SIGNAL(clicked()),this,SLOT(OnGeneratePw())); connect(ButtonGenerate,SIGNAL(clicked()),this,SLOT(OnGeneratePw()));
connect(Radio_1,SIGNAL(toggled(bool)),this,SLOT(OnRadio1StateChanged(bool))); connect(Radio_1,SIGNAL(toggled(bool)),this,SLOT(OnRadio1StateChanged(bool)));
connect(Radio_2,SIGNAL(toggled(bool)),this,SLOT(OnRadio2StateChanged(bool))); connect(Radio_2,SIGNAL(toggled(bool)),this,SLOT(OnRadio2StateChanged(bool)));

@ -11,8 +11,8 @@
</property> </property>
<property name="sizePolicy" > <property name="sizePolicy" >
<sizepolicy> <sizepolicy>
<hsizetype>0</hsizetype> <hsizetype>5</hsizetype>
<vsizetype>0</vsizetype> <vsizetype>5</vsizetype>
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
@ -23,12 +23,6 @@
<height>230</height> <height>230</height>
</size> </size>
</property> </property>
<property name="maximumSize" >
<size>
<width>432</width>
<height>230</height>
</size>
</property>
<property name="windowTitle" > <property name="windowTitle" >
<string>Random Number Generator</string> <string>Random Number Generator</string>
</property> </property>
@ -84,6 +78,20 @@ Please move the mouse and/or press some keys until enought entropy for a reseed
</item> </item>
<item> <item>
<widget class="QStackedWidget" name="stackedWidget" > <widget class="QStackedWidget" name="stackedWidget" >
<property name="sizePolicy" >
<sizepolicy>
<hsizetype>5</hsizetype>
<vsizetype>1</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<size>
<width>16</width>
<height>45</height>
</size>
</property>
<property name="currentIndex" > <property name="currentIndex" >
<number>0</number> <number>0</number>
</property> </property>

@ -5,30 +5,18 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>460</width> <width>462</width>
<height>470</height> <height>458</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy" > <property name="sizePolicy" >
<sizepolicy> <sizepolicy>
<hsizetype>0</hsizetype> <hsizetype>4</hsizetype>
<vsizetype>0</vsizetype> <vsizetype>4</vsizetype>
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="minimumSize" >
<size>
<width>460</width>
<height>470</height>
</size>
</property>
<property name="maximumSize" >
<size>
<width>460</width>
<height>470</height>
</size>
</property>
<property name="windowTitle" > <property name="windowTitle" >
<string>Password Generator</string> <string>Password Generator</string>
</property> </property>
@ -62,7 +50,7 @@
</property> </property>
<layout class="QVBoxLayout" > <layout class="QVBoxLayout" >
<property name="margin" > <property name="margin" >
<number>10</number> <number>9</number>
</property> </property>
<property name="spacing" > <property name="spacing" >
<number>6</number> <number>6</number>
@ -102,40 +90,37 @@
</spacer> </spacer>
</item> </item>
<item> <item>
<layout class="QVBoxLayout" > <layout class="QGridLayout" >
<property name="margin" > <property name="margin" >
<number>0</number> <number>0</number>
</property> </property>
<property name="spacing" > <property name="spacing" >
<number>0</number> <number>6</number>
</property> </property>
<item> <item row="1" column="0" >
<widget class="QCheckBox" name="checkBox1" > <widget class="QCheckBox" name="checkBox2" >
<property name="text" > <property name="text" >
<string>&amp;Upper Letters</string> <string>&amp;Lower Letters</string>
</property> </property>
<property name="shortcut" > <property name="shortcut" >
<string>Alt+U</string> <string>Alt+L</string>
</property> </property>
<property name="checked" > <property name="checked" >
<bool>true</bool> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item row="2" column="1" >
<widget class="QCheckBox" name="checkBox2" > <widget class="QCheckBox" name="checkBox7" >
<property name="text" > <property name="text" >
<string>&amp;Lower Letters</string> <string>U&amp;nderline</string>
</property> </property>
<property name="shortcut" > <property name="shortcut" >
<string>Alt+L</string> <string>Alt+N</string>
</property>
<property name="checked" >
<bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item row="2" column="0" >
<widget class="QCheckBox" name="checkBox3" > <widget class="QCheckBox" name="checkBox3" >
<property name="text" > <property name="text" >
<string>&amp;Numbers</string> <string>&amp;Numbers</string>
@ -148,66 +133,46 @@
</property> </property>
</widget> </widget>
</item> </item>
<item> <item row="0" column="1" >
<widget class="QCheckBox" name="checkBox4" > <widget class="QCheckBox" name="checkBox5" >
<property name="text" > <property name="text" >
<string>&amp;Special Characters</string> <string>White &amp;Spaces</string>
</property> </property>
<property name="checked" > <property name="shortcut" >
<bool>true</bool> <string>Alt+S</string>
</property> </property>
</widget> </widget>
</item> </item>
</layout> <item row="0" column="0" >
</item> <widget class="QCheckBox" name="checkBox1" >
<item>
<layout class="QVBoxLayout" >
<property name="margin" >
<number>0</number>
</property>
<property name="spacing" >
<number>0</number>
</property>
<item>
<widget class="QCheckBox" name="checkBox5" >
<property name="text" > <property name="text" >
<string>White &amp;Spaces</string> <string>&amp;Upper Letters</string>
</property> </property>
<property name="shortcut" > <property name="shortcut" >
<string>Alt+S</string> <string>Alt+U</string>
</property>
<property name="checked" >
<bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item row="1" column="1" >
<widget class="QCheckBox" name="checkBox6" > <widget class="QCheckBox" name="checkBox6" >
<property name="text" > <property name="text" >
<string>Minus</string> <string>Minus</string>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item row="3" column="0" >
<widget class="QCheckBox" name="checkBox7" > <widget class="QCheckBox" name="checkBox4" >
<property name="text" > <property name="text" >
<string>U&amp;nderline</string> <string>&amp;Special Characters</string>
</property> </property>
<property name="shortcut" > <property name="checked" >
<string>Alt+N</string> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item>
<spacer>
<property name="orientation" >
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" >
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</item> </item>
<item> <item>
@ -217,8 +182,8 @@
</property> </property>
<property name="sizeHint" > <property name="sizeHint" >
<size> <size>
<width>40</width> <width>101</width>
<height>20</height> <height>108</height>
</size> </size>
</property> </property>
</spacer> </spacer>
@ -273,10 +238,13 @@
<property name="orientation" > <property name="orientation" >
<enum>Qt::Vertical</enum> <enum>Qt::Vertical</enum>
</property> </property>
<property name="sizeType" >
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" > <property name="sizeHint" >
<size> <size>
<width>20</width> <width>20</width>
<height>20</height> <height>25</height>
</size> </size>
</property> </property>
</spacer> </spacer>
@ -382,6 +350,22 @@
</property> </property>
</widget> </widget>
</item> </item>
<item>
<spacer>
<property name="orientation" >
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" >
<size>
<width>10</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item> <item>
<widget class="QCheckBox" name="Check_CollectOncePerSession" > <widget class="QCheckBox" name="Check_CollectOncePerSession" >
<property name="text" > <property name="text" >

@ -77,6 +77,7 @@ KeepassMainWindow::KeepassMainWindow(const QString& ArgFile,QWidget *parent, Qt:
Start=true; Start=true;
ShutingDown=false; ShutingDown=false;
setupUi(this); setupUi(this);
setUnifiedTitleAndToolBarOnMac(true);
AutoType::MainWin=this; AutoType::MainWin=this;
setGeometry(settings->value("Ui/MainWindowGeometry",QVariant(geometry())).toRect()); setGeometry(settings->value("Ui/MainWindowGeometry",QVariant(geometry())).toRect());
VSplitter->restoreState(settings->value("Ui/VSplitterPos").toByteArray()); VSplitter->restoreState(settings->value("Ui/VSplitterPos").toByteArray());