diff --git a/texter/texter/build.sh b/texter/texter/build.sh
index 2239a83..5a54324 100644
--- a/texter/texter/build.sh
+++ b/texter/texter/build.sh
@@ -1,2 +1,2 @@
-# pykdeuic4-python2.7 -o texter_ui.py texter3.ui
-pykdeuic4-python2.7 -o text_sorter_ui.py texter4.ui
+pyuic4 -o texter_ui.py texter3.ui
+# pykdeuic4-python2.7 -o text_sorter_ui.py texter4.ui
diff --git a/texter/texter/main.py b/texter/texter/main.py
index 8c827a7..85c44c5 100644
--- a/texter/texter/main.py
+++ b/texter/texter/main.py
@@ -12,6 +12,7 @@ from operator import itemgetter
from PyQt4 import QtCore, QtGui
+
from PyKDE4.kdecore import ki18n, KCmdLineArgs, KAboutData
from PyKDE4.kdeui import KDialog, KActionCollection, KRichTextWidget, KComboBox, KPushButton, KRichTextWidget, KMainWindow, KToolBar, KApplication, KAction, KToolBarSpacerAction, KSelectAction, KToggleAction, KShortcut
@@ -106,6 +107,104 @@ class TextSorterDialog(QtGui.QWidget, Ui_TextSorterDialog):
self.text_list.clicked.emit(index)
+class TextAnimation(QtCore.QObject):
+ animation_started = QtCore.pyqtSignal()
+ animation_finished = QtCore.pyqtSignal()
+ animation_stopped = QtCore.pyqtSignal()
+
+ def __init__(self, parent=None):
+ super(TextAnimation, self).__init__(parent)
+ self.animated_document = None
+ self.cursor_position = 0
+ self.src_cursor = None
+ self.area = None
+ self.dst_cursor = None
+ self.text = None
+ self.it = None
+ self.timer = None
+ self.dst_current_block = None
+
+ def start_animation(self, animated_document, area, cursor_position):
+ print "start_animation", animated_document, area, cursor_position
+ if self.timer is not None:
+ print "timer is not None"
+ return False
+ self.animated_document = animated_document
+ self.area = area
+ self.cursor_position = cursor_position
+
+ self.src_cursor = QtGui.QTextCursor(self.animated_document)
+ self.src_cursor.setPosition(0)
+
+ self.dst_cursor = self.area.textCursor()
+ self.dst_cursor.setPosition(self.cursor_position)
+ self.timer = QtCore.QTimer(self)
+ self.timer.timeout.connect(self.slot_animate)
+ parent = self.parent()
+ parent.slot_clear_live()
+ #self.dst_cursor.setPosition(self.cursor_position)
+ self.timer.start(70)
+ print "timer started"
+ return True
+
+ def slot_animate(self):
+ print "slot_animate"
+ self.animation_started.emit()
+ parent = self.parent()
+
+ if self.it is None:
+ self.it = self.animated_document.rootFrame().begin()
+ #self.src_block = self.it.currentBlock()
+ #area_rootFrame = self.area.document().rootFrame()
+ #area_rootFrame.setFrameFormat(rootFrame.frameFormat())
+ #print "it is none", repr(self.src_block.text())
+
+ if not self.it.atEnd():
+ if self.text is None:
+ self.src_block = self.it.currentBlock()
+ text = unicode(self.src_block.text())
+ print "text", repr(text)
+ self.text = iter(text)
+ src_block_format = self.src_block.blockFormat()
+ if self.dst_current_block is not None:
+ print "insert new block"
+ self.dst_cursor.insertBlock(src_block_format)
+ self.dst_current_block = self.dst_current_block.next()
+ else:
+ self.dst_current_block = self.dst_cursor.block()
+ dst_char_format = self.dst_current_block.charFormat()
+ src_char_format = self.src_block.charFormat()
+ src_font_point_size = src_char_format.fontPointSize()
+ dst_char_format.setFontPointSize(src_font_point_size)
+ print "src font size", src_font_point_size
+ parent.default_size = src_font_point_size
+ parent.font.setPointSize(parent.default_size)
+ parent.live_text.setFontSize(parent.default_size)
+ parent.live_text.setFont(parent.font)
+ parent.live_size_action.setFontSize(parent.default_size)
+ #parent.live_text.document().setDefaultFont(parent.font)
+
+ try:
+ char = self.text.next()
+ print "char", char
+ self.dst_cursor.insertText(char)
+ except StopIteration:
+ print "end of block"
+ self.it += 1
+ self.text = None
+ else:
+ self.timer.stop()
+ self.timer.timeout.disconnect(self.slot_animate)
+ self.timer.deleteLater()
+ self.dst_current_block = None
+ self.it = None
+ self.text = None
+ self.animation_finished.emit()
+ self.timer = None
+ print "animation end"
+ print
+
+
class MainWindow(KMainWindow, Ui_MainWindow):
def __init__(self, parent=None):
super(MainWindow, self).__init__(parent)
@@ -125,6 +224,8 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.live_actions = list()
self.current = 0
self.model = TextModel(self)
+ self.animation = TextAnimation(self)
+ self.db_dirty = False
self.is_auto_publish = False
@@ -142,22 +243,22 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.createLiveActions()
self.createPreviewActions()
- self.slot_load()
- self.preview_text.document().setDefaultFont(self.font)
+ #self.preview_text.document().setDefaultFont(self.font)
self.preview_text.setFont(self.font)
self.preview_text.setRichTextSupport(KRichTextWidget.RichTextSupport(0xffffffff))
self.preview_editor_collection = KActionCollection(self)
self.preview_text.createActions(self.preview_editor_collection)
self.live_text.setRichTextSupport(KRichTextWidget.RichTextSupport(0xffffffff))
- self.live_text.document().setDefaultFont(self.font)
+ #self.live_text.document().setDefaultFont(self.font)
self.live_text.setFont(self.font)
self.live_editor_collection = KActionCollection(self)
self.live_text.createActions(self.live_editor_collection)
self.filter_editor_actions()
self.toolbar.insertSeparator(self.publish_action)
self.toolbar.addSeparator()
+ self.slot_load()
self.show()
@@ -181,7 +282,6 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.next_action.triggered.connect(self.slot_next_item)
self.previous_action.triggered.connect(self.slot_previous_item)
- app.aboutToQuit.connect(self.kill_streaming)
self.getLiveCoords()
print "desktop", app.desktop().availableGeometry()
@@ -309,12 +409,10 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.next_action.setIconText("next")
self.next_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.ALT + QtCore.Qt.Key_Right)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
- self.text_editor_action = KToggleAction(self.preview_text_collection)
+ self.text_editor_action = self.preview_text_collection.addAction("text_editor_action")
icon = QtGui.QIcon.fromTheme(_fromUtf8("document-open"))
self.text_editor_action.setIcon(icon)
- self.text_editor_action.setIconText("sort")
- self.preview_text_collection.addAction("text editor", self.text_editor_action)
- self.text_editor_action.setObjectName("text_editor_action")
+ self.text_editor_action.setIconText("edit")
self.text_editor_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.CTRL + QtCore.Qt.Key_O)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
self.auto_publish_action = KToggleAction(self.preview_text_collection)
@@ -323,6 +421,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.auto_publish_action.setIcon(icon)
self.auto_publish_action.setObjectName("auto_publish_action")
self.auto_publish_action.setIconText("auto publish")
+ self.auto_publish_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.CTRL + QtCore.Qt.Key_P)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
self.save_action = self.preview_text_collection.addAction("save_action")
icon = QtGui.QIcon.fromTheme(_fromUtf8("document-save"))
@@ -338,11 +437,11 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.streaming_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.CTRL + QtCore.Qt.Key_1)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
self.preview_text_collection.addAction("stream", self.streaming_action)
- #self.valign_action = self.preview_text_collection.addAction("valign_action")
- #icon = QtGui.QIcon.fromTheme(_fromUtf8("media-stop"))
- #self.valign_action.setIcon(icon)
- #self.valign_action.setIconText("valign")
- #self.valign_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.CTRL + QtCore.Qt.Key_Plus)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
+ self.valign_action = self.preview_text_collection.addAction("valign_action")
+ icon = QtGui.QIcon.fromTheme(_fromUtf8("media-stop"))
+ self.valign_action.setIcon(icon)
+ self.valign_action.setIconText("valign")
+ self.valign_action.setShortcut(KShortcut(QtGui.QKeySequence(QtCore.Qt.CTRL + QtCore.Qt.Key_Plus)), KAction.ShortcutTypes(KAction.ActiveShortcut | KAction.DefaultShortcut))
self.spacer = KToolBarSpacerAction(self.preview_text_collection)
self.preview_text_collection.addAction("spacer", self.spacer)
@@ -355,18 +454,18 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.text_combo.setObjectName("text_combo")
self.preview_text_collection.addAction("saved texts", self.text_combo)
- def slot_auto_publish(self, state):
- self.is_auto_publish = bool(state)
+ def closeEvent(self, event):
+ self.stop_streaming()
+ if self.db_dirty:
+ self.dialog = KDialog(self)
+ self.dialog.setCaption("4.48 texter - text db not saved")
+ label = QtGui.QLabel("The Text database is not saved. Do you want to save before exit?", self.dialog)
+ self.dialog.setMainWidget(label)
+ self.dialog.setButtons(KDialog.ButtonCodes(KDialog.Ok | KDialog.Cancel))
+ self.dialog.okClicked.connect(self.slot_save)
+ self.dialog.exec_()
-
- def slot_toggle_streaming(self):
- if self.ffserver is None:
- self.start_streaming()
- else:
- self.kill_streaming()
-
-
- def kill_streaming(self):
+ def stop_streaming(self):
self.is_streaming = False
if self.ffmpeg is not None:
self.ffmpeg.kill()
@@ -402,6 +501,17 @@ class MainWindow(KMainWindow, Ui_MainWindow):
return re.sub(" +", " ", text.replace("\n", " ")).strip()[:20]
+ def slot_auto_publish(self, state):
+ self.is_auto_publish = bool(state)
+
+
+ def slot_toggle_streaming(self):
+ if self.ffserver is None:
+ self.start_streaming()
+ else:
+ self.stop_streaming()
+
+
def slot_next_item(self):
self.current = (self.text_combo.currentItem() + 1) % len(self.model.text_db)
self.text_combo.setCurrentItem(self.current)
@@ -422,7 +532,10 @@ class MainWindow(KMainWindow, Ui_MainWindow):
def slot_publish(self):
- self.live_text.setTextOrHtml(self.preview_text.textOrHtml())
+ print "publish"
+ #self.live_text.setTextOrHtml(self.preview_text.textOrHtml())
+ self.animation.start_animation(self.preview_text.document(), self.live_text, 0)
+ self.slot_clear_live()
def slot_live_font_size(self, action):
print "font_size"
@@ -453,7 +566,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.preview_text.setFontSize(self.default_size)
self.preview_text.setFont(self.font)
self.preview_size_action.setFontSize(self.default_size)
- self.preview_text.document().setDefaultFont(self.font)
+ #self.preview_text.document().setDefaultFont(self.font)
def slot_set_live_defaults(self):
@@ -463,7 +576,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.live_text.setFontSize(self.default_size)
self.live_text.setFont(self.font)
self.live_size_action.setFontSize(self.default_size)
- self.live_text.document().setDefaultFont(self.font)
+ #self.live_text.document().setDefaultFont(self.font)
def slot_clear_live(self):
@@ -506,7 +619,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
return
self.preview_text.setTextOrHtml(text)
if self.is_auto_publish:
- self.live_text.setTextOrHtml(text)
+ self.slot_publish()
def slot_save_live_text(self):
@@ -530,6 +643,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.model.modelReset.emit()
action = self.text_combo.addAction(preview)
self.text_combo.setCurrentAction(action)
+ self.db_dirty = True
def slot_save_preview_text(self):
text = self.preview_text.toHtml()
@@ -553,6 +667,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.model.modelReset.emit()
action = self.text_combo.addAction(preview)
self.text_combo.setCurrentAction(action)
+ self.db_dirty = True
def slot_save(self):
path = os.path.expanduser("~/.texter")
@@ -617,6 +732,9 @@ class MainWindow(KMainWindow, Ui_MainWindow):
#painter.drawEllipse(QtCore.QRectF(-radius, margin, 2*radius, 2*radius))
#painter.end()
+ def slot_valign(self):
+ self.animation = TextAnimation(self.preview_text.document(), )
+
def slot_open_dialog(self):
self.dialog = KDialog(self)
self.dialog_widget = TextSorterDialog(self.dialog)
@@ -628,8 +746,10 @@ class MainWindow(KMainWindow, Ui_MainWindow):
global_height = rect.height()
x = global_width - pos_x - 10
self.dialog.setFixedSize(x, global_height-40);
+ self.dialog.okClicked.connect(self.fill_combo_box)
self.dialog.exec_()
- self.fill_combo_box()
+ self.dialog.deleteLater()
+ self.dialog = None
def slot_load(self):
path = os.path.expanduser("~/.texter")
@@ -648,7 +768,7 @@ class MainWindow(KMainWindow, Ui_MainWindow):
self.fill_combo_box()
self.text_combo.setCurrentItem(0)
self.slot_load_preview_text(0)
- self.slot_load_preview_text(0)
+
def main():
diff --git a/texter/texter/text_sorter_ui.py b/texter/texter/text_sorter_ui.py
index 5e34386..da3d9e0 100644
--- a/texter/texter/text_sorter_ui.py
+++ b/texter/texter/text_sorter_ui.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python
# coding=UTF-8
#
-# Generated by pykdeuic4 from texter4.ui on Wed Apr 16 00:27:54 2014
+# Generated by pykdeuic4 from texter4.ui on Sat Apr 19 19:39:29 2014
#
# WARNING! All changes to this file will be lost.
from PyKDE4 import kdecore
@@ -25,49 +25,203 @@ except AttributeError:
class Ui_TextSorterDialog(object):
def setupUi(self, TextSorterDialog):
TextSorterDialog.setObjectName(_fromUtf8("TextSorterDialog"))
- TextSorterDialog.resize(662, 716)
+ TextSorterDialog.resize(1073, 938)
self.verticalLayout = QtGui.QVBoxLayout(TextSorterDialog)
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.horizontalLayout_2 = QtGui.QHBoxLayout()
self.horizontalLayout_2.setObjectName(_fromUtf8("horizontalLayout_2"))
self.text_list = QtGui.QListView(TextSorterDialog)
+ sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
+ sizePolicy.setHorizontalStretch(2)
+ sizePolicy.setVerticalStretch(0)
+ sizePolicy.setHeightForWidth(self.text_list.sizePolicy().hasHeightForWidth())
+ self.text_list.setSizePolicy(sizePolicy)
self.text_list.setMinimumSize(QtCore.QSize(0, 576))
self.text_list.setMaximumSize(QtCore.QSize(16777215, 576))
palette = QtGui.QPalette()
brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.WindowText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Text, brush)
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.WindowText, brush)
brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Text, brush)
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush)
+ brush = QtGui.QBrush(QtGui.QColor(128, 125, 123))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.WindowText, brush)
brush = QtGui.QBrush(QtGui.QColor(128, 125, 123))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Text, brush)
- brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush)
self.text_list.setPalette(palette)
self.text_list.setObjectName(_fromUtf8("text_list"))
self.horizontalLayout_2.addWidget(self.text_list)
self.text_preview = KRichTextWidget(TextSorterDialog)
- self.text_preview.setMinimumSize(QtCore.QSize(0, 576))
- self.text_preview.setMaximumSize(QtCore.QSize(16777215, 576))
+ sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
+ sizePolicy.setHorizontalStretch(8)
+ sizePolicy.setVerticalStretch(0)
+ sizePolicy.setHeightForWidth(self.text_preview.sizePolicy().hasHeightForWidth())
+ self.text_preview.setSizePolicy(sizePolicy)
+ self.text_preview.setMinimumSize(QtCore.QSize(200, 576))
+ self.text_preview.setMaximumSize(QtCore.QSize(768, 576))
palette = QtGui.QPalette()
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.WindowText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Button, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Light, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Midlight, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Dark, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Mid, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Text, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.BrightText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ButtonText, brush)
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
- palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Shadow, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.AlternateBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 220))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipText, brush)
brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.WindowText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Button, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Light, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Midlight, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Dark, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Mid, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Text, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.BrightText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ButtonText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Shadow, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.AlternateBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 220))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.WindowText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Button, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Light, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Midlight, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Dark, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Mid, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Text, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.BrightText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ButtonText, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Shadow, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.AlternateBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(255, 255, 220))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipBase, brush)
+ brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
+ brush.setStyle(QtCore.Qt.SolidPattern)
+ palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipText, brush)
self.text_preview.setPalette(palette)
self.text_preview.setReadOnly(True)
self.text_preview.setObjectName(_fromUtf8("text_preview"))
diff --git a/texter/texter/texter3.ui b/texter/texter/texter3.ui
index bb7834f..34ecd42 100644
--- a/texter/texter/texter3.ui
+++ b/texter/texter/texter3.ui
@@ -218,7 +218,7 @@
- BlankCursor
+ ArrowCursor
true
diff --git a/texter/texter/texter4.ui b/texter/texter/texter4.ui
index bf97ac0..2ff8e33 100644
--- a/texter/texter/texter4.ui
+++ b/texter/texter/texter4.ui
@@ -6,8 +6,8 @@
0
0
- 662
- 716
+ 1073
+ 938
@@ -18,6 +18,12 @@
-
+
+
+ 2
+ 0
+
+
0
@@ -33,6 +39,15 @@
+
+
+
+ 255
+ 255
+ 255
+
+
+
@@ -51,8 +66,26 @@
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
@@ -71,8 +104,26 @@
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 128
+ 125
+ 123
+
+
+
@@ -85,9 +136,18 @@
- 255
- 255
- 255
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
@@ -98,21 +158,108 @@
-
+
+
+ 8
+ 0
+
+
- 0
+ 200
576
- 16777215
+ 768
576
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
@@ -122,8 +269,134 @@
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 220
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
@@ -133,9 +406,117 @@
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 220
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
-
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
255
@@ -144,6 +525,69 @@
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
+
+
+
+ 255
+ 255
+ 220
+
+
+
+
+
+
+ 0
+ 0
+ 0
+
+
+
diff --git a/texter/texter/texter_ui.py b/texter/texter/texter_ui.py
index 730e3c3..c6f94c7 100644
--- a/texter/texter/texter_ui.py
+++ b/texter/texter/texter_ui.py
@@ -2,7 +2,7 @@
# Form implementation generated from reading ui file 'texter3.ui'
#
-# Created: Wed Apr 16 20:48:51 2014
+# Created: Sat Apr 19 21:56:41 2014
# by: PyQt4 UI code generator 4.10.3
#
# WARNING! All changes made in this file will be lost!
@@ -57,8 +57,8 @@ class Ui_MainWindow(object):
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.live_text = KRichTextWidget(self.centralwidget)
- self.live_text.setMinimumSize(QtCore.QSize(772,580))
- self.live_text.setMaximumSize(QtCore.QSize(772,580))
+ self.live_text.setMinimumSize(QtCore.QSize(775, 578))
+ self.live_text.setMaximumSize(QtCore.QSize(775, 578))
palette = QtGui.QPalette()
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)
@@ -97,7 +97,7 @@ class Ui_MainWindow(object):
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Link, brush)
self.live_text.setPalette(palette)
- self.live_text.viewport().setProperty("cursor", QtGui.QCursor(QtCore.Qt.BlankCursor))
+ self.live_text.viewport().setProperty("cursor", QtGui.QCursor(QtCore.Qt.ArrowCursor))
self.live_text.setAutoFillBackground(True)
self.live_text.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.live_text.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
@@ -113,7 +113,7 @@ class Ui_MainWindow(object):
sizePolicy.setHeightForWidth(self.preview_text.sizePolicy().hasHeightForWidth())
self.preview_text.setSizePolicy(sizePolicy)
self.preview_text.setMinimumSize(QtCore.QSize(300, 577))
- self.preview_text.setMaximumSize(QtCore.QSize(772,580))
+ self.preview_text.setMaximumSize(QtCore.QSize(769, 577))
palette = QtGui.QPalette()
brush = QtGui.QBrush(QtGui.QColor(0, 0, 0))
brush.setStyle(QtCore.Qt.SolidPattern)