Added the start to a song plugin, and a bare (for now) SettingsTab class.

bzr-revno: 114
This commit is contained in:
Raoul Snyman 2008-11-23 21:24:58 +00:00
parent 808748a008
commit dec6feb03c
7 changed files with 58 additions and 48 deletions

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE UserProject SYSTEM "UserProject-4.0.dtd"> <!DOCTYPE UserProject SYSTEM "UserProject-4.0.dtd">
<!-- eric4 user project file for project openlp.org 2.0 --> <!-- eric4 user project file for project openlp.org 2.0 -->
<!-- Saved: 2008-11-22, 23:40:11 --> <!-- Saved: 2008-11-23, 23:21:19 -->
<!-- Copyright (C) 2008 Raoul Snyman, raoulsnyman@openlp.org --> <!-- Copyright (C) 2008 Raoul Snyman, raoulsnyman@openlp.org -->
<UserProject version="4.0"> <UserProject version="4.0">
</UserProject> </UserProject>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Tasks SYSTEM "Tasks-4.2.dtd"> <!DOCTYPE Tasks SYSTEM "Tasks-4.2.dtd">
<!-- eric4 tasks file for project openlp.org 2.0 --> <!-- eric4 tasks file for project openlp.org 2.0 -->
<!-- Saved: 2008-11-22, 23:40:11 --> <!-- Saved: 2008-11-23, 23:21:19 -->
<Tasks version="4.2"> <Tasks version="4.2">
</Tasks> </Tasks>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Project SYSTEM "Project-4.4.dtd"> <!DOCTYPE Project SYSTEM "Project-4.4.dtd">
<!-- eric4 project file for project openlp.org 2.0 --> <!-- eric4 project file for project openlp.org 2.0 -->
<!-- Saved: 2008-11-22, 17:14:47 --> <!-- Saved: 2008-11-23, 23:21:19 -->
<!-- Copyright (C) 2008 Raoul Snyman, raoulsnyman@openlp.org --> <!-- Copyright (C) 2008 Raoul Snyman, raoulsnyman@openlp.org -->
<Project version="4.4"> <Project version="4.4">
<ProgLanguage mixed="0">Python</ProgLanguage> <ProgLanguage mixed="0">Python</ProgLanguage>
@ -70,6 +70,8 @@
<Source>openlp/plugins/biblemanager/test/test_bibleManagerOSIS.py</Source> <Source>openlp/plugins/biblemanager/test/test_bibleManagerOSIS.py</Source>
<Source>openlp/core/pluginmanager.py</Source> <Source>openlp/core/pluginmanager.py</Source>
<Source>openlp/core/mediamanageritem.py</Source> <Source>openlp/core/mediamanageritem.py</Source>
<Source>openlp/core/settingstab.py</Source>
<Source>openlp/plugins/song/songplugin.py</Source>
</Sources> </Sources>
<Forms> <Forms>
<Form>openlp/resources/forms/mainwindow.ui</Form> <Form>openlp/resources/forms/mainwindow.ui</Form>

View File

@ -17,6 +17,7 @@ You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc., 59 Temple this program; if not, write to the Free Software Foundation, Inc., 59 Temple
Place, Suite 330, Boston, MA 02111-1307 USA Place, Suite 330, Boston, MA 02111-1307 USA
""" """
import types
from PyQt4 import QtCore, QtGui from PyQt4 import QtCore, QtGui
from openlp.resources import * from openlp.resources import *
@ -30,15 +31,15 @@ class MediaManagerItem(QtGui.QWidget):
Constructor to create the media manager item. Constructor to create the media manager item.
""" """
QtGui.QWidget.__init__(self) QtGui.QWidget.__init__(self)
self.Icon = QtGui.QIcon() if type(icon) is QtGui.QIcon:
if icon is not None: self.Icon = icon
self.Icon.addPixmap(QtGui.QPixmap.fromImage(QtGui.QImage(icon)), QtGui.QIcon.Normal, QtGui.QIcon.Off) elif type(icon) is types.StringType:
self.Icon.addPixmap(QtGui.QPixmap.fromImage(QtGui.QImage(icon)),
QtGui.QIcon.Normal, QtGui.QIcon.Off)
else: else:
self.Icon = None self.Icon = None
if title is not None: if title is not None:
self.Title = title self.Title = title
else:
self.Title = ''
self.Toolbar = None self.Toolbar = None
def addToolbar(self): def addToolbar(self):

View File

@ -51,6 +51,7 @@ class Plugin(object):
string which can be written to the service file string which can be written to the service file
""" """
pass pass
def load(self, str): def load(self, str):
""" """
A string from the service file is passed in. This function parses and A string from the service file is passed in. This function parses and

View File

@ -0,0 +1,25 @@
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=80
"""
OpenLP - Open Source Lyrics Projection
Copyright (c) 2008 Raoul Snyman
Portions copyright (c) 2008 Martin Thompson, Tim Bentley
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation; version 2 of the License.
This program is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
Place, Suite 330, Boston, MA 02111-1307 USA
"""
from PyQt4 import QtCore, QtGui
from openlp.resources import *
class SettingsTab(QtGui.QWidget):
pass

View File

@ -5,8 +5,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>721</width> <width>724</width>
<height>441</height> <height>502</height>
</rect> </rect>
</property> </property>
<property name="windowTitle" > <property name="windowTitle" >
@ -963,44 +963,25 @@ p, li { white-space: pre-wrap; }
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QWidget" native="1" name="ButtonsBar" > <widget class="QDialogButtonBox" name="ButtonsBox" >
<layout class="QHBoxLayout" name="ButtonsLayout" > <property name="sizePolicy" >
<property name="spacing" > <sizepolicy vsizetype="Minimum" hsizetype="Expanding" >
<number>0</number> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="margin" > </sizepolicy>
<number>0</number> </property>
</property> <property name="maximumSize" >
<item> <size>
<spacer name="ButtonsSpacer" > <width>16777215</width>
<property name="orientation" > <height>16777215</height>
<enum>Qt::Horizontal</enum> </size>
</property> </property>
<property name="sizeHint" stdset="0" > <property name="orientation" >
<size> <enum>Qt::Horizontal</enum>
<width>40</width> </property>
<height>20</height> <property name="standardButtons" >
</size> <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property> </property>
</spacer>
</item>
<item>
<widget class="QDialogButtonBox" name="ButtonsBox" >
<property name="maximumSize" >
<size>
<width>341</width>
<height>16777215</height>
</size>
</property>
<property name="orientation" >
<enum>Qt::Horizontal</enum>
</property>
<property name="standardButtons" >
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>
</layout>
</widget> </widget>
</item> </item>
</layout> </layout>