Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
falkTX committed Apr 1, 2018
1 parent 34421dd commit 13ad391
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 41 deletions.
12 changes: 2 additions & 10 deletions welcome/welcome.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ def do_copy_theme(fontSize, copy_all=False):
os.system("cp '%s/%s' '%s/.%s'" % (CONFIG_THEME_DIR, sfile, HOME, sfile))
os.system("sed -i s/_X-FONTSIZE-X_/%i/ '%s/.%s'" % (fontSize, HOME, sfile))

os.system('gconftool-2 -t str -s /apps/metacity/general/theme "KXStudio"')
#os.system('gconftool-2 -t str -s /apps/metacity/general/theme "KXStudio"')
os.system('gconftool-2 -t str -s /apps/metacity/general/button_layout "close,minimize,maximize:menu"')
os.system('gconftool-2 -t str -s /apps/metacity/general/titlebar_font "DejaVu Sans Bold %i"' % fontSize)
os.system('gconftool-2 -t str -s /apps/nautilus/preferences/desktop_font "DejaVu Sans %i"' % fontSize)
Expand Down Expand Up @@ -313,13 +313,6 @@ def __init__(self, firstRun, parent=None):
if firstRun:
self.label_7.setVisible(False)

# TODO
self.label_5.setEnabled(False)
self.label_5.setVisible(False)
self.cb_style.setEnabled(False)
self.cb_style.setVisible(False)
# Update your theme to one of the KXStudio defaults.<br/>You can choose the <b>classic dark and flat</b> or a new <b>light green unity-like</b> style.

QTimer.singleShot(0, self.disableNext)

def checkNext(self, clicked):
Expand All @@ -335,9 +328,8 @@ def enableNext(self):
self.button(QWizard.NextButton).setEnabled(True)

def showScreenshot(self):
styleIndex = self.cb_style.currentIndex()
box = QMessageBox(self)
box.setIconPixmap(QPixmap(os.path.join(PWD, "icons", "screenshot-green.png" if styleIndex != 0 else "screenshot-black.png")))
box.setIconPixmap(QPixmap(os.path.join(PWD, "icons", "screenshot-black.png")))
box.setWindowTitle(self.tr("Welcome to KXStudio - Screenshot"))
box.exec_()

Expand Down
41 changes: 10 additions & 31 deletions welcome/welcome.ui
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>615</width>
<height>509</height>
<height>565</height>
</rect>
</property>
<property name="windowTitle">
Expand Down Expand Up @@ -130,7 +130,7 @@ Please select one of the options below or uncheck &quot;Update settings&quot;, a
<item>
<widget class="QRadioButton" name="rb_basic">
<property name="text">
<string>Update basic settings</string>
<string>&amp;Update basic settings</string>
</property>
</widget>
</item>
Expand Down Expand Up @@ -253,7 +253,7 @@ Use it to clean up your settings, or if you just installed KXStudio.</string>
</sizepolicy>
</property>
<property name="title">
<string>Update theme</string>
<string>Update &amp;theme</string>
</property>
<property name="flat">
<bool>true</bool>
Expand Down Expand Up @@ -288,29 +288,15 @@ Use it to clean up your settings, or if you just installed KXStudio.</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Note that reverting back theme changes is not trivial, so &lt;b&gt;be sure this is what you want&lt;/b&gt;.</string>
</property>
</widget>
</item>
<item row="2" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QLabel" name="label_5">
<property name="text">
<string>Style: (TODO)</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="cb_style">
<item>
<property name="text">
<string>Classic dark and flat</string>
</property>
</item>
<item>
<property name="text">
<string>Unity-like light green</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLabel" name="label_4">
<property name="text">
Expand Down Expand Up @@ -360,13 +346,6 @@ Use it to clean up your settings, or if you just installed KXStudio.</string>
</item>
</layout>
</item>
<item row="1" column="1">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Note that reverting back theme changes is not trivial, so &lt;b&gt;be sure this is what you want&lt;/b&gt;.</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
Expand Down

0 comments on commit 13ad391

Please sign in to comment.