diff --git a/OpenLP.spec b/OpenLP.spec deleted file mode 100644 index 9569af6c1..000000000 --- a/OpenLP.spec +++ /dev/null @@ -1,19 +0,0 @@ -# -*- mode: python -*- -a = Analysis([os.path.join(HOMEPATH,'support\\_mountzlib.py'), os.path.join(HOMEPATH,'support\\useUnicode.py'), 'openlp.pyw'], - pathex=[os.path.abspath('.')]) -pyz = PYZ(a.pure) -exe = EXE(pyz, - a.scripts, - exclude_binaries=1, - name=os.path.join('build\\pyi.win32\\OpenLP', 'OpenLP.exe'), - debug=False, - strip=False, - upx=True, - console=False , icon='resources\\images\\OpenLP.ico') -coll = COLLECT( exe, - a.binaries, - a.zipfiles, - a.datas, - strip=False, - upx=True, - name=os.path.join('dist', 'OpenLP')) diff --git a/documentation/Makefile b/documentation/api/Makefile similarity index 100% rename from documentation/Makefile rename to documentation/api/Makefile diff --git a/documentation/make.bat b/documentation/api/make.bat similarity index 100% rename from documentation/make.bat rename to documentation/api/make.bat diff --git a/documentation/source/conf.py b/documentation/api/source/conf.py similarity index 96% rename from documentation/source/conf.py rename to documentation/api/source/conf.py index 86ad3b7de..51ecfee0c 100644 --- a/documentation/source/conf.py +++ b/documentation/api/source/conf.py @@ -17,7 +17,7 @@ import sys # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.append(os.path.abspath(os.path.join('..', '..'))) +sys.path.insert(0, os.path.abspath(os.path.join('..', '..', '..'))) # -- General configuration ----------------------------------------------------- @@ -39,7 +39,7 @@ master_doc = 'index' # General information about the project. project = u'OpenLP' -copyright = u'2009, Raoul Snyman' +copyright = u'2004-2010, Raoul Snyman' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -48,7 +48,7 @@ copyright = u'2009, Raoul Snyman' # The short X.Y version. version = '2.0' # The full version, including alpha/beta/rc tags. -release = '2.0.pre' +release = '1.9.3' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. @@ -111,7 +111,7 @@ html_theme_options = { # The name for this set of Sphinx documents. If None, it defaults to # " v documentation". -#html_title = None +html_title = 'OpenLP 2.0 Developer API' # A shorter title for the navigation bar. Default is the same as html_title. #html_short_title = None @@ -166,7 +166,7 @@ html_static_path = ['_static'] #html_file_suffix = '' # Output file base name for HTML help builder. -htmlhelp_basename = 'OpenLPdoc' +htmlhelp_basename = 'OpenLP-2.0-api' # -- Options for LaTeX output -------------------------------------------------- @@ -180,7 +180,7 @@ htmlhelp_basename = 'OpenLPdoc' # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, author, documentclass [howto/manual]). latex_documents = [ - ('index', 'OpenLP.tex', u'OpenLP Documentation', + ('index', 'OpenLP.tex', u'OpenLP 2.0 Developer API', u'Raoul Snyman', 'manual'), ] diff --git a/documentation/source/core/index.rst b/documentation/api/source/core/index.rst similarity index 100% rename from documentation/source/core/index.rst rename to documentation/api/source/core/index.rst diff --git a/documentation/source/core/lib.rst b/documentation/api/source/core/lib.rst similarity index 92% rename from documentation/source/core/lib.rst rename to documentation/api/source/core/lib.rst index 43ca90b3b..5fc66200d 100644 --- a/documentation/source/core/lib.rst +++ b/documentation/api/source/core/lib.rst @@ -60,12 +60,6 @@ .. autoclass:: openlp.core.lib.settingstab.SettingsTab :members: -:mod:`ThemeXML` ---------------- - -.. autoclass:: openlp.core.lib.themexmlhandler.ThemeXML - :members: - :mod:`OpenLPToolbar` -------------------- diff --git a/documentation/source/core/theme.rst b/documentation/api/source/core/theme.rst similarity index 100% rename from documentation/source/core/theme.rst rename to documentation/api/source/core/theme.rst diff --git a/documentation/source/index.rst b/documentation/api/source/index.rst similarity index 100% rename from documentation/source/index.rst rename to documentation/api/source/index.rst diff --git a/documentation/source/openlp.rst b/documentation/api/source/openlp.rst similarity index 100% rename from documentation/source/openlp.rst rename to documentation/api/source/openlp.rst diff --git a/documentation/api/source/plugins/bibles.rst b/documentation/api/source/plugins/bibles.rst new file mode 100644 index 000000000..67162d414 --- /dev/null +++ b/documentation/api/source/plugins/bibles.rst @@ -0,0 +1,55 @@ +.. _plugins-bibles: + +Bibles Plugin +============= + +.. automodule:: openlp.plugins.bibles + :members: + +Plugin Class +------------ + +.. autoclass:: openlp.plugins.bibles.bibleplugin.BiblePlugin + :members: + +Forms +----- + +.. automodule:: openlp.plugins.bibles.forms + :members: + +.. autoclass:: openlp.plugins.bibles.forms.importwizardform.ImportWizardForm + :members: + +Helper Classes & Functions +-------------------------- + +.. automodule:: openlp.plugins.bibles.lib + :members: + +.. automodule:: openlp.plugins.bibles.lib.db + :members: + +.. automodule:: openlp.plugins.bibles.lib.biblestab + :members: + +.. automodule:: openlp.plugins.bibles.lib.manager + :members: + +.. automodule:: openlp.plugins.bibles.lib.mediaitem + :members: + +Bible Importers +--------------- + +.. automodule:: openlp.plugins.bibles.lib.csvbible + :members: + +.. automodule:: openlp.plugins.bibles.lib.http + :members: + +.. automodule:: openlp.plugins.bibles.lib.osis + :members: + +.. automodule:: openlp.plugins.bibles.lib.opensong + :members: diff --git a/documentation/api/source/plugins/images.rst b/documentation/api/source/plugins/images.rst new file mode 100644 index 000000000..1007fc64c --- /dev/null +++ b/documentation/api/source/plugins/images.rst @@ -0,0 +1,22 @@ +.. _plugins-images: + +Images Plugin +============= + +.. automodule:: openlp.plugins.images + :members: + +Plugin Class +------------ + +.. autoclass:: openlp.plugins.images.imageplugin.ImagePlugin + :members: + +Helper Classes & Functions +-------------------------- + +.. automodule:: openlp.plugins.images.lib + :members: + +.. automodule:: openlp.plugins.images.lib.mediaitem + :members: diff --git a/documentation/source/plugins/index.rst b/documentation/api/source/plugins/index.rst similarity index 54% rename from documentation/source/plugins/index.rst rename to documentation/api/source/plugins/index.rst index 713005c3d..6c5b139d5 100644 --- a/documentation/source/plugins/index.rst +++ b/documentation/api/source/plugins/index.rst @@ -11,24 +11,9 @@ songs bibles - -:mod:`presentations` Plugin ---------------------------- - -.. automodule:: openlp.plugins.presentations - :members: - -:mod:`media` Plugin -------------------- - -.. automodule:: openlp.plugins.media - :members: - -:mod:`images` Plugin --------------------- - -.. automodule:: openlp.plugins.images - :members: + presentations + media + images :mod:`custom` Plugin -------------------- diff --git a/documentation/api/source/plugins/media.rst b/documentation/api/source/plugins/media.rst new file mode 100644 index 000000000..a8486c9b4 --- /dev/null +++ b/documentation/api/source/plugins/media.rst @@ -0,0 +1,22 @@ +.. _plugins-media: + +Media Plugin +============ + +.. automodule:: openlp.plugins.media + :members: + +Plugin Class +------------ + +.. autoclass:: openlp.plugins.media.mediaplugin.MediaPlugin + :members: + +Helper Classes & Functions +-------------------------- + +.. automodule:: openlp.plugins.media.lib + :members: + +.. automodule:: openlp.plugins.media.lib.mediaitem + :members: diff --git a/documentation/api/source/plugins/presentations.rst b/documentation/api/source/plugins/presentations.rst new file mode 100644 index 000000000..dd688ddf6 --- /dev/null +++ b/documentation/api/source/plugins/presentations.rst @@ -0,0 +1,40 @@ +.. _plugins-presentations: + +Presentations Plugin +==================== + +Plugin Class +------------ + +.. autoclass:: openlp.plugins.presentations.presentationplugin.PresentationPlugin + :members: + +Helper Classes & Functions +-------------------------- + +.. automodule:: openlp.plugins.presentations.lib + :members: + +.. automodule:: openlp.plugins.presentations.lib.mediaitem + :members: + +.. automodule:: openlp.plugins.presentations.lib.presentationtab + :members: + +.. automodule:: openlp.plugins.presentations.lib.messagelistener + :members: + +.. automodule:: openlp.plugins.presentations.lib.presentationcontroller + :members: + +Presentation Application Controllers +------------------------------------ + +.. automodule:: openlp.plugins.presentations.lib.impresscontroller + :members: + +.. automodule:: openlp.plugins.presentations.lib.pptviewcontroller + :members: + +.. automodule:: openlp.plugins.presentations.lib.powerpointcontroller + :members: diff --git a/documentation/api/source/plugins/songs.rst b/documentation/api/source/plugins/songs.rst new file mode 100644 index 000000000..fed9907a2 --- /dev/null +++ b/documentation/api/source/plugins/songs.rst @@ -0,0 +1,103 @@ +.. _plugins-songs: + +Songs Plugin +============ + +.. automodule:: openlp.plugins.songs + :members: + +Plugin Class +------------ + +.. autoclass:: openlp.plugins.songs.songsplugin.SongsPlugin + :members: + +Forms +----- + +.. automodule:: openlp.plugins.songs.forms + :members: + +.. autoclass:: openlp.plugins.songs.forms.authorsform.AuthorsForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.editsongform.EditSongForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.editverseform.EditVerseForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.songbookform.SongBookForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.songimportform.SongImportForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.songmaintenanceform.SongMaintenanceForm + :members: + +.. autoclass:: openlp.plugins.songs.forms.topicsform.TopicsForm + :members: + +Helper Classes & Functions +-------------------------- + +.. automodule:: openlp.plugins.songs.lib + :members: + +.. automodule:: openlp.plugins.songs.lib.db + :members: + +.. automodule:: openlp.plugins.songs.lib.importer + :members: + +.. automodule:: openlp.plugins.songs.lib.mediaitem + :members: + +.. autoclass:: openlp.plugins.songs.lib.mediaitem.SongListView + :members: + +.. automodule:: openlp.plugins.songs.lib.songimport + :members: + +.. automodule:: openlp.plugins.songs.lib.songstab + :members: + +.. automodule:: openlp.plugins.songs.lib.xml + :members: + +Song Importers +-------------- + +.. automodule:: openlp.plugins.songs.lib.cclifileimport + :members: + +.. autoclass:: openlp.plugins.songs.lib.cclifileimport.CCLIFileImportError + :members: + +.. automodule:: openlp.plugins.songs.lib.ewimport + :members: + +.. autoclass:: openlp.plugins.songs.lib.ewimport.FieldDescEntry + :members: + +.. automodule:: openlp.plugins.songs.lib.olp1import + :members: + +.. automodule:: openlp.plugins.songs.lib.olpimport + :members: + +.. automodule:: openlp.plugins.songs.lib.oooimport + :members: + +.. automodule:: openlp.plugins.songs.lib.opensongimport + :members: + +.. automodule:: openlp.plugins.songs.lib.sofimport + :members: + +.. automodule:: openlp.plugins.songs.lib.songbeamerimport + :members: + +.. automodule:: openlp.plugins.songs.lib.wowimport + :members: diff --git a/documentation/manual/Makefile b/documentation/manual/Makefile new file mode 100644 index 000000000..70c821142 --- /dev/null +++ b/documentation/manual/Makefile @@ -0,0 +1,88 @@ +# Makefile for Sphinx documentation +# + +# You can set these variables from the command line. +SPHINXOPTS = +SPHINXBUILD = sphinx-build +PAPER = + +# Internal variables. +PAPEROPT_a4 = -D latex_paper_size=a4 +PAPEROPT_letter = -D latex_paper_size=letter +ALLSPHINXOPTS = -d build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source + +.PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest + +help: + @echo "Please use \`make ' where is one of" + @echo " html to make standalone HTML files" + @echo " dirhtml to make HTML files named index.html in directories" + @echo " pickle to make pickle files" + @echo " json to make JSON files" + @echo " htmlhelp to make HTML files and a HTML help project" + @echo " qthelp to make HTML files and a qthelp project" + @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" + @echo " changes to make an overview of all changed/added/deprecated items" + @echo " linkcheck to check all external links for integrity" + @echo " doctest to run all doctests embedded in the documentation (if enabled)" + +clean: + -rm -rf build/* + +html: + $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) build/html + @echo + @echo "Build finished. The HTML pages are in build/html." + +dirhtml: + $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) build/dirhtml + @echo + @echo "Build finished. The HTML pages are in build/dirhtml." + +pickle: + $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) build/pickle + @echo + @echo "Build finished; now you can process the pickle files." + +json: + $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) build/json + @echo + @echo "Build finished; now you can process the JSON files." + +htmlhelp: + $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) build/htmlhelp + @echo + @echo "Build finished; now you can run HTML Help Workshop with the" \ + ".hhp project file in build/htmlhelp." + +qthelp: + $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) build/qthelp + @echo + @echo "Build finished; now you can run "qcollectiongenerator" with the" \ + ".qhcp project file in build/qthelp, like this:" + @echo "# qcollectiongenerator build/qthelp/OpenLP.qhcp" + @echo "To view the help file:" + @echo "# assistant -collectionFile build/qthelp/OpenLP.qhc" + +latex: + $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) build/latex + @echo + @echo "Build finished; the LaTeX files are in build/latex." + @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \ + "run these through (pdf)latex." + +changes: + $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) build/changes + @echo + @echo "The overview file is in build/changes." + +linkcheck: + $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) build/linkcheck + @echo + @echo "Link check complete; look for any errors in the above output " \ + "or in build/linkcheck/output.txt." + +doctest: + $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) build/doctest + @echo "Testing of doctests in the sources finished, look at the " \ + "results in build/doctest/output.txt." diff --git a/documentation/manual/make.bat b/documentation/manual/make.bat new file mode 100644 index 000000000..8d21b45ce --- /dev/null +++ b/documentation/manual/make.bat @@ -0,0 +1,112 @@ +@ECHO OFF + +REM Command file for Sphinx documentation + +set SPHINXBUILD=sphinx-build +set ALLSPHINXOPTS=-d build/doctrees %SPHINXOPTS% source +if NOT "%PAPER%" == "" ( + set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS% +) + +if "%1" == "" goto help + +if "%1" == "help" ( + :help + echo.Please use `make ^` where ^ is one of + echo. html to make standalone HTML files + echo. dirhtml to make HTML files named index.html in directories + echo. pickle to make pickle files + echo. json to make JSON files + echo. htmlhelp to make HTML files and a HTML help project + echo. qthelp to make HTML files and a qthelp project + echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter + echo. changes to make an overview over all changed/added/deprecated items + echo. linkcheck to check all external links for integrity + echo. doctest to run all doctests embedded in the documentation if enabled + goto end +) + +if "%1" == "clean" ( + for /d %%i in (build\*) do rmdir /q /s %%i + del /q /s build\* + goto end +) + +if "%1" == "html" ( + %SPHINXBUILD% -b html %ALLSPHINXOPTS% build/html + echo. + echo.Build finished. The HTML pages are in build/html. + goto end +) + +if "%1" == "dirhtml" ( + %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% build/dirhtml + echo. + echo.Build finished. The HTML pages are in build/dirhtml. + goto end +) + +if "%1" == "pickle" ( + %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% build/pickle + echo. + echo.Build finished; now you can process the pickle files. + goto end +) + +if "%1" == "json" ( + %SPHINXBUILD% -b json %ALLSPHINXOPTS% build/json + echo. + echo.Build finished; now you can process the JSON files. + goto end +) + +if "%1" == "htmlhelp" ( + %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% build/htmlhelp + echo. + echo.Build finished; now you can run HTML Help Workshop with the ^ +.hhp project file in build/htmlhelp. + goto end +) + +if "%1" == "qthelp" ( + %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% build/qthelp + echo. + echo.Build finished; now you can run "qcollectiongenerator" with the ^ +.qhcp project file in build/qthelp, like this: + echo.^> qcollectiongenerator build\qthelp\OpenLP.qhcp + echo.To view the help file: + echo.^> assistant -collectionFile build\qthelp\OpenLP.ghc + goto end +) + +if "%1" == "latex" ( + %SPHINXBUILD% -b latex %ALLSPHINXOPTS% build/latex + echo. + echo.Build finished; the LaTeX files are in build/latex. + goto end +) + +if "%1" == "changes" ( + %SPHINXBUILD% -b changes %ALLSPHINXOPTS% build/changes + echo. + echo.The overview file is in build/changes. + goto end +) + +if "%1" == "linkcheck" ( + %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% build/linkcheck + echo. + echo.Link check complete; look for any errors in the above output ^ +or in build/linkcheck/output.txt. + goto end +) + +if "%1" == "doctest" ( + %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% build/doctest + echo. + echo.Testing of doctests in the sources finished, look at the ^ +results in build/doctest/output.txt. + goto end +) + +:end diff --git a/documentation/manual/source/conf.py b/documentation/manual/source/conf.py new file mode 100644 index 000000000..517fc2f44 --- /dev/null +++ b/documentation/manual/source/conf.py @@ -0,0 +1,208 @@ +# -*- coding: utf-8 -*- +# +# OpenLP documentation build configuration file, created by +# sphinx-quickstart on Fri Jul 10 17:20:40 2009. +# +# This file is execfile()d with the current directory set to its containing dir. +# +# Note that not all possible configuration values are present in this +# autogenerated file. +# +# All configuration values have a default; values that are commented out +# serve to show the default. + +import os +import sys + +# If extensions (or modules to document with autodoc) are in another directory, +# add these directories to sys.path here. If the directory is relative to the +# documentation root, use os.path.abspath to make it absolute, like shown here. +#sys.path.insert(0, os.path.abspath(os.path.join('..', '..'))) + +# -- General configuration ----------------------------------------------------- + +# Add any Sphinx extension module names here, as strings. They can be extensions +# coming with Sphinx (named 'sphinx.ext.*') or your custom ones. +#extensions = ['sphinx.ext.autodoc'] + +# Add any paths that contain templates here, relative to this directory. +templates_path = ['_templates'] + +# The suffix of source filenames. +source_suffix = '.rst' + +# The encoding of source files. +source_encoding = 'utf-8' + +# The master toctree document. +master_doc = 'index' + +# General information about the project. +project = u'OpenLP' +copyright = u'2004-2010 Raoul Snyman' + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. +# +# The short X.Y version. +version = '2.0' +# The full version, including alpha/beta/rc tags. +release = '1.9.3' + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +#language = None + +# There are two options for replacing |today|: either, you set today to some +# non-false value, then it is used: +#today = '' +# Else, today_fmt is used as the format for a strftime call. +#today_fmt = '%B %d, %Y' + +# List of documents that shouldn't be included in the build. +#unused_docs = [] + +# List of directories, relative to source directory, that shouldn't be searched +# for source files. +exclude_trees = [] + +# The reST default role (used for this markup: `text`) to use for all documents. +#default_role = None + +# If true, '()' will be appended to :func: etc. cross-reference text. +#add_function_parentheses = True + +# If true, the current module name will be prepended to all description +# unit titles (such as .. function::). +add_module_names = False + +# If true, sectionauthor and moduleauthor directives will be shown in the +# output. They are ignored by default. +#show_authors = False + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# A list of ignored prefixes for module index sorting. +#modindex_common_prefix = [] + + +# -- Options for HTML output --------------------------------------------------- + +# The theme to use for HTML and HTML Help pages. Major themes that come with +# Sphinx are currently 'default' and 'sphinxdoc'. +html_theme = 'default' + +# Theme options are theme-specific and customize the look and feel of a theme +# further. For a list of options available for each theme, see the +# documentation. +html_theme_options = { + 'sidebarbgcolor': '#3a60a9', + 'relbarbgcolor': '#203b6f', + 'footerbgcolor': '#26437c', + 'headtextcolor': '#203b6f', + 'linkcolor': '#26437c', + 'sidebarlinkcolor': '#ceceff' +} + +# Add any paths that contain custom themes here, relative to this directory. +#html_theme_path = [] + +# The name for this set of Sphinx documents. If None, it defaults to +# " v documentation". +html_title = u'OpenLP 2.0 User Manual' + +# A shorter title for the navigation bar. Default is the same as html_title. +#html_short_title = None + +# The name of an image file (relative to this directory) to place at the top +# of the sidebar. +#html_logo = None + +# The name of an image file (within the static path) to use as favicon of the +# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 +# pixels large. +#html_favicon = None + +# Add any paths that contain custom static files (such as style sheets) here, +# relative to this directory. They are copied after the builtin static files, +# so a file named "default.css" will overwrite the builtin "default.css". +html_static_path = ['_static'] + +# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, +# using the given strftime format. +#html_last_updated_fmt = '%b %d, %Y' + +# If true, SmartyPants will be used to convert quotes and dashes to +# typographically correct entities. +#html_use_smartypants = True + +# Custom sidebar templates, maps document names to template names. +#html_sidebars = {} + +# Additional templates that should be rendered to pages, maps page names to +# template names. +#html_additional_pages = {} + +# If false, no module index is generated. +#html_use_modindex = True + +# If false, no index is generated. +#html_use_index = True + +# If true, the index is split into individual pages for each letter. +#html_split_index = False + +# If true, links to the reST sources are added to the pages. +#html_show_sourcelink = True + +# If true, an OpenSearch description file will be output, and all pages will +# contain a tag referring to it. The value of this option must be the +# base URL from which the finished HTML is served. +#html_use_opensearch = '' + +# If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml"). +#html_file_suffix = '' + +# Output file base name for HTML help builder. +htmlhelp_basename = 'OpenLP-2.0-manual' + + +# -- Options for LaTeX output -------------------------------------------------- + +# The paper size ('letter' or 'a4'). +#latex_paper_size = 'letter' + +# The font size ('10pt', '11pt' or '12pt'). +#latex_font_size = '10pt' + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, author, documentclass [howto/manual]). +latex_documents = [ + ('index', 'OpenLP.tex', u'OpenLP 2.0 User Manual', + u'Raoul Snyman', 'manual'), +] + +# The name of an image file (relative to this directory) to place at the top of +# the title page. +#latex_logo = None + +# For "manual" documents, if this is true, then toplevel headings are parts, +# not chapters. +#latex_use_parts = False + +# Additional stuff for the LaTeX preamble. +#latex_preamble = '' + +# Documents to append as an appendix to all manuals. +#latex_appendices = [] + +# If false, no module index is generated. +#latex_use_modindex = True + +# A dictionary that contains LaTeX snippets that override those Sphinx usually +# puts into the generated .tex files. +latex_elements = { + 'fontpkg': '\\usepackage{helvet}' +} diff --git a/documentation/source/manual/dualmonitors.rst b/documentation/manual/source/dualmonitors.rst similarity index 100% rename from documentation/source/manual/dualmonitors.rst rename to documentation/manual/source/dualmonitors.rst diff --git a/documentation/source/manual/glossary.rst b/documentation/manual/source/glossary.rst similarity index 94% rename from documentation/source/manual/glossary.rst rename to documentation/manual/source/glossary.rst index c99a00c4e..41a8f4ac6 100644 --- a/documentation/source/manual/glossary.rst +++ b/documentation/manual/source/glossary.rst @@ -9,21 +9,22 @@ be used throughout this documentation, and when seeking support. Main Window ----------- -The Main Window is what you will see when you first open OpenLP. -The Main Window contains all the tools and plugins that make OpenLP function. +The Main Window is what you will see when you first open OpenLP .. image:: pics/mainwindow.png +The Main Window contains all the tools and plugins that make OpenLP function + Media Manager ------------- The Media Manager contains a number of tabs that plugins supply to OpenLP. Each tab in the Media Manager is called a **Media Item** -From the Media Manager you can send Media Items to the Preview or Live screens. - .. image:: pics/mediamanager.png +From the Media Manager you can send Media Items to the Preview or Live screens. + Preview ------- @@ -43,7 +44,7 @@ Service Item A service item are the **media items** that are in the **service manager** -Service Manager +Service Manger -------------- The service manager contains the media items in your service file. This is the diff --git a/documentation/source/manual/index.rst b/documentation/manual/source/index.rst similarity index 83% rename from documentation/source/manual/index.rst rename to documentation/manual/source/index.rst index 180555cbb..ac29c4360 100644 --- a/documentation/source/manual/index.rst +++ b/documentation/manual/source/index.rst @@ -3,8 +3,8 @@ You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. -Welcome to OpenLP's documentation -================================== +Welcome to the OpenLP 2.0 User Manual +===================================== Contents: diff --git a/documentation/source/manual/introduction.rst b/documentation/manual/source/introduction.rst similarity index 100% rename from documentation/source/manual/introduction.rst rename to documentation/manual/source/introduction.rst diff --git a/documentation/source/manual/pics/dvi.png b/documentation/manual/source/pics/dvi.png similarity index 100% rename from documentation/source/manual/pics/dvi.png rename to documentation/manual/source/pics/dvi.png diff --git a/documentation/source/manual/pics/gnome.png b/documentation/manual/source/pics/gnome.png similarity index 100% rename from documentation/source/manual/pics/gnome.png rename to documentation/manual/source/pics/gnome.png diff --git a/documentation/source/manual/pics/kdedisplay.png b/documentation/manual/source/pics/kdedisplay.png similarity index 100% rename from documentation/source/manual/pics/kdedisplay.png rename to documentation/manual/source/pics/kdedisplay.png diff --git a/documentation/source/manual/pics/kdesystemsettings.png b/documentation/manual/source/pics/kdesystemsettings.png similarity index 100% rename from documentation/source/manual/pics/kdesystemsettings.png rename to documentation/manual/source/pics/kdesystemsettings.png diff --git a/documentation/source/manual/pics/mainwindow.png b/documentation/manual/source/pics/mainwindow.png similarity index 100% rename from documentation/source/manual/pics/mainwindow.png rename to documentation/manual/source/pics/mainwindow.png diff --git a/documentation/source/manual/pics/mediamanager.png b/documentation/manual/source/pics/mediamanager.png similarity index 100% rename from documentation/source/manual/pics/mediamanager.png rename to documentation/manual/source/pics/mediamanager.png diff --git a/documentation/source/manual/pics/nvlinux1.png b/documentation/manual/source/pics/nvlinux1.png similarity index 100% rename from documentation/source/manual/pics/nvlinux1.png rename to documentation/manual/source/pics/nvlinux1.png diff --git a/documentation/source/manual/pics/preview.png b/documentation/manual/source/pics/preview.png similarity index 100% rename from documentation/source/manual/pics/preview.png rename to documentation/manual/source/pics/preview.png diff --git a/documentation/source/manual/pics/servicemanager.png b/documentation/manual/source/pics/servicemanager.png similarity index 100% rename from documentation/source/manual/pics/servicemanager.png rename to documentation/manual/source/pics/servicemanager.png diff --git a/documentation/source/manual/pics/slidecontroller.png b/documentation/manual/source/pics/slidecontroller.png similarity index 100% rename from documentation/source/manual/pics/slidecontroller.png rename to documentation/manual/source/pics/slidecontroller.png diff --git a/documentation/source/manual/pics/thememanager.png b/documentation/manual/source/pics/thememanager.png similarity index 100% rename from documentation/source/manual/pics/thememanager.png rename to documentation/manual/source/pics/thememanager.png diff --git a/documentation/source/manual/pics/twinview.png b/documentation/manual/source/pics/twinview.png similarity index 100% rename from documentation/source/manual/pics/twinview.png rename to documentation/manual/source/pics/twinview.png diff --git a/documentation/source/manual/pics/vga.png b/documentation/manual/source/pics/vga.png similarity index 100% rename from documentation/source/manual/pics/vga.png rename to documentation/manual/source/pics/vga.png diff --git a/documentation/source/manual/pics/vistadisplaysettings.png b/documentation/manual/source/pics/vistadisplaysettings.png similarity index 100% rename from documentation/source/manual/pics/vistadisplaysettings.png rename to documentation/manual/source/pics/vistadisplaysettings.png diff --git a/documentation/source/manual/pics/vistapersonalize.png b/documentation/manual/source/pics/vistapersonalize.png similarity index 100% rename from documentation/source/manual/pics/vistapersonalize.png rename to documentation/manual/source/pics/vistapersonalize.png diff --git a/documentation/source/manual/pics/winsevendisplay.png b/documentation/manual/source/pics/winsevendisplay.png similarity index 100% rename from documentation/source/manual/pics/winsevendisplay.png rename to documentation/manual/source/pics/winsevendisplay.png diff --git a/documentation/source/manual/pics/winsevenresolution.png b/documentation/manual/source/pics/winsevenresolution.png similarity index 100% rename from documentation/source/manual/pics/winsevenresolution.png rename to documentation/manual/source/pics/winsevenresolution.png diff --git a/documentation/source/manual/pics/xorgwrite.png b/documentation/manual/source/pics/xorgwrite.png similarity index 100% rename from documentation/source/manual/pics/xorgwrite.png rename to documentation/manual/source/pics/xorgwrite.png diff --git a/documentation/source/manual/pics/xpdisplaysettings.png b/documentation/manual/source/pics/xpdisplaysettings.png similarity index 100% rename from documentation/source/manual/pics/xpdisplaysettings.png rename to documentation/manual/source/pics/xpdisplaysettings.png diff --git a/documentation/source/plugins/bibles.rst b/documentation/source/plugins/bibles.rst deleted file mode 100644 index c042feb56..000000000 --- a/documentation/source/plugins/bibles.rst +++ /dev/null @@ -1,95 +0,0 @@ -.. _plugins-bibles: - -:mod:`bibles` Plugin -==================== - -.. automodule:: openlp.plugins.bibles - :members: - -:mod:`BiblePlugin` Class -------------------------- - -.. autoclass:: openlp.plugins.bibles.bibleplugin.BiblePlugin - :members: - -:mod:`forms` Submodule ----------------------- - -.. automodule:: openlp.plugins.bibles.forms - :members: - -:mod:`BibleImportWizard` -^^^^^^^^^^^^^^^^^^^^^^^^ - -.. autoclass:: openlp.plugins.bibles.forms.bibleimportwizard.Ui_BibleImportWizard - :members: - -.. autoclass:: openlp.plugins.bibles.forms.importwizardform.ImportWizardForm - :members: - -:mod:`lib` Submodule --------------------- - -.. automodule:: openlp.plugins.bibles.lib - :members: - -:mod:`db` -^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.db - :members: - -.. autoclass:: openlp.plugins.bibles.lib.db.BibleDB - :members: - -:mod:`csv` -^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.csvbible - :members: - -.. autoclass:: openlp.plugins.bibles.lib.csvbible.CSVBible - :members: - -:mod:`http` -^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.http - :members: - -.. autoclass:: openlp.plugins.bibles.lib.http.HTTPBible - :members: - -:mod:`bibleOSISimpl` -^^^^^^^^^^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.osis - :members: - -.. autoclass:: openlp.plugins.bibles.lib.osis.OSISBible - :members: - -:mod:`biblestab` -^^^^^^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.biblestab - :members: - -:mod:`common` -^^^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.common - :members: - -:mod:`manager` -^^^^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.manager - :members: - -:mod:`mediaitem` -^^^^^^^^^^^^^^^^ - -.. automodule:: openlp.plugins.bibles.lib.mediaitem - :members: - diff --git a/documentation/source/plugins/songs.rst b/documentation/source/plugins/songs.rst deleted file mode 100644 index fab10f02d..000000000 --- a/documentation/source/plugins/songs.rst +++ /dev/null @@ -1,46 +0,0 @@ -.. _plugins-songs: - -:mod:`songs` Plugin -=================== - -.. automodule:: openlp.plugins.songs - :members: - -:mod:`SongsPlugin` Class ------------------------- - -.. autoclass:: openlp.plugins.songs.songsplugin.SongsPlugin - :members: - -:mod:`forms` Submodule ----------------------- - -.. automodule:: openlp.plugins.songs.forms - :members: - -:mod:`AuthorsForm` -^^^^^^^^^^^^^^^^^^ - -.. autoclass:: openlp.plugins.songs.forms.authorsdialog.Ui_AuthorsDialog - :members: - -.. autoclass:: openlp.plugins.songs.forms.authorsform.AuthorsForm - :members: - -:mod:`EditSongForm` -^^^^^^^^^^^^^^^^^^^ - -.. autoclass:: openlp.plugins.songs.forms.editsongdialog.Ui_EditSongDialog - :members: - -.. autoclass:: openlp.plugins.songs.forms.editsongform.EditSongForm - :members: - -:mod:`EditVerseForm` -^^^^^^^^^^^^^^^^^^^^ - -.. autoclass:: openlp.plugins.songs.forms.editversedialog.Ui_EditVerseDialog - :members: - -.. autoclass:: openlp.plugins.songs.forms.editverseform.EditVerseForm - :members: diff --git a/openlp.pyw b/openlp.pyw index 80b49321e..17743903f 100755 --- a/openlp.pyw +++ b/openlp.pyw @@ -30,6 +30,7 @@ import sys import logging from optparse import OptionParser from traceback import format_exception +from subprocess import Popen, PIPE from PyQt4 import QtCore, QtGui @@ -71,6 +72,84 @@ class OpenLP(QtGui.QApplication): """ log.info(u'OpenLP Application Loaded') + def _get_version(self): + """ + Load and store current Application Version + """ + if u'--dev-version' in sys.argv: + # If we're running the dev version, let's use bzr to get the version + try: + # If bzrlib is availble, use it + from bzrlib.branch import Branch + b = Branch.open_containing('.')[0] + b.lock_read() + try: + # Get the branch's latest revision number. + revno = b.revno() + # Convert said revision number into a bzr revision id. + revision_id = b.dotted_revno_to_revision_id((revno,)) + # Get a dict of tags, with the revision id as the key. + tags = b.tags.get_reverse_tag_dict() + # Check if the latest + if revision_id in tags: + full_version = u'%s' % tags[revision_id][0] + else: + full_version = '%s-bzr%s' % \ + (sorted(b.tags.get_tag_dict().keys())[-1], revno) + finally: + b.unlock() + except: + # Otherwise run the command line bzr client + bzr = Popen((u'bzr', u'tags', u'--sort', u'time'), stdout=PIPE) + output, error = bzr.communicate() + code = bzr.wait() + if code != 0: + raise Exception(u'Error running bzr tags') + lines = output.splitlines() + if len(lines) == 0: + tag = u'0.0.0' + revision = u'0' + else: + tag, revision = lines[-1].split() + bzr = Popen((u'bzr', u'log', u'--line', u'-r', u'-1'), + stdout=PIPE) + output, error = bzr.communicate() + code = bzr.wait() + if code != 0: + raise Exception(u'Error running bzr log') + latest = output.split(u':')[0] + full_version = latest == revision and tag or \ + u'%s-bzr%s' % (tag, latest) + else: + # We're not running the development version, let's use the file + filepath = AppLocation.get_directory(AppLocation.VersionDir) + filepath = os.path.join(filepath, u'.version') + fversion = None + try: + fversion = open(filepath, u'r') + full_version = unicode(fversion.read()).rstrip() + except IOError: + log.exception('Error in version file.') + full_version = u'0.0.0-bzr000' + finally: + if fversion: + fversion.close() + bits = full_version.split(u'-') + app_version = { + u'full': full_version, + u'version': bits[0], + u'build': bits[1] if len(bits) > 1 else None + } + if app_version[u'build']: + log.info( + u'Openlp version %s build %s', + app_version[u'version'], + app_version[u'build'] + ) + else: + log.info(u'Openlp version %s' % app_version[u'version']) + return app_version + def notify(self, obj, evt): #TODO needed for presentation exceptions return QtGui.QApplication.notify(self, obj, evt) @@ -79,39 +158,7 @@ class OpenLP(QtGui.QApplication): """ Run the OpenLP application. """ - #Load and store current Application Version - filepath = AppLocation.get_directory(AppLocation.VersionDir) - filepath = os.path.join(filepath, u'.version') - fversion = None - try: - fversion = open(filepath, u'r') - for line in fversion: - full_version = unicode(line).rstrip() #\ - #.replace(u'\r', u'').replace(u'\n', u'') - bits = full_version.split(u'-') - app_version = { - u'full': full_version, - u'version': bits[0], - u'build': bits[1] if len(bits) > 1 else None - } - if app_version[u'build']: - log.info( - u'Openlp version %s build %s', - app_version[u'version'], - app_version[u'build'] - ) - else: - log.info(u'Openlp version %s' % app_version[u'version']) - except IOError: - log.exception('Error in version file.') - app_version = { - u'full': u'1.9.0-bzr000', - u'version': u'1.9.0', - u'build': u'bzr000' - } - finally: - if fversion: - fversion.close() + app_version = self._get_version() #provide a listener for widgets to reqest a screen update. QtCore.QObject.connect(Receiver.get_receiver(), QtCore.SIGNAL(u'openlp_process_events'), self.processEvents) @@ -172,6 +219,9 @@ def main(): parser.add_option('-p', '--portable', dest='portable', action='store_true', help='Specify if this should be run as a ' 'portable app, off a USB flash drive (not implemented).') + parser.add_option('-d', '--dev-version', dest='dev_version', + action='store_true', help='Ignore the version file and pull the ' + 'version directly from Bazaar') parser.add_option('-s', '--style', dest='style', help='Set the Qt4 style (passed directly to Qt4).') # Set up logging diff --git a/openlp/core/lib/__init__.py b/openlp/core/lib/__init__.py index 560450741..b43c491ff 100644 --- a/openlp/core/lib/__init__.py +++ b/openlp/core/lib/__init__.py @@ -223,16 +223,13 @@ def image_to_byte(image): ``image`` The image to converted. """ - log.debug(u'image_to_byte') + log.debug(u'image_to_byte - start') byte_array = QtCore.QByteArray() # use buffer to store pixmap into byteArray buffie = QtCore.QBuffer(byte_array) buffie.open(QtCore.QIODevice.WriteOnly) - if isinstance(image, QtGui.QImage): - pixmap = QtGui.QPixmap.fromImage(image) - else: - pixmap = QtGui.QPixmap(image) - pixmap.save(buffie, "PNG") + image.save(buffie, "PNG") + log.debug(u'image_to_byte - end') # convert to base64 encoding so does not get missed! return byte_array.toBase64() @@ -253,8 +250,11 @@ def resize_image(image, width, height, background=QtCore.Qt.black): The background colour defaults to black. """ - log.debug(u'resize_image') - preview = QtGui.QImage(image) + log.debug(u'resize_image - start') + if isinstance(image, QtGui.QImage): + preview = image + else: + preview = QtGui.QImage(image) if not preview.isNull(): # Only resize if different size if preview.width() == width and preview.height == height: @@ -263,6 +263,7 @@ def resize_image(image, width, height, background=QtCore.Qt.black): QtCore.Qt.SmoothTransformation) image_cache_key = u'%s%s%s' % (image, unicode(width), unicode(height)) if image_cache_key in image_cache: + log.debug(u'resize_image - end cache') return image_cache[image_cache_key] realw = preview.width() realh = preview.height() @@ -273,6 +274,7 @@ def resize_image(image, width, height, background=QtCore.Qt.black): painter = QtGui.QPainter(new_image) painter.drawImage((width - realw) / 2, (height - realh) / 2, preview) image_cache[image_cache_key] = new_image + log.debug(u'resize_image - end') return new_image def check_item_selected(list_widget, message): @@ -313,7 +315,7 @@ def expand_tags(text): from spelltextedit import SpellTextEdit from eventreceiver import Receiver from settingsmanager import SettingsManager -from plugin import PluginStatus, Plugin +from plugin import PluginStatus, StringContent, Plugin from pluginmanager import PluginManager from settingstab import SettingsTab from serviceitem import ServiceItem diff --git a/openlp/core/lib/eventreceiver.py b/openlp/core/lib/eventreceiver.py index a4f683e81..1080cd2f5 100644 --- a/openlp/core/lib/eventreceiver.py +++ b/openlp/core/lib/eventreceiver.py @@ -75,7 +75,7 @@ class EventReceiver(QtCore.QObject): Broadcasts that an item has been made live/previewed ``slidecontroller_{live|preview}_change`` - Informs the slidecontroller that a slide change has occurred and to + Informs the slidecontroller that a slide change has occurred and to update itself ``slidecontroller_{live|preview}_changed`` @@ -83,7 +83,7 @@ class EventReceiver(QtCore.QObject): ``slidecontroller_{live|preview}_text_request`` Request the text for the current item in the controller - Returns a slidecontroller_{live|preview}_text_response with an + Returns a slidecontroller_{live|preview}_text_response with an array of dictionaries with the tag and verse text ``slidecontroller_{live|preview}_blank`` @@ -106,23 +106,23 @@ class EventReceiver(QtCore.QObject): ``servicemanager_set_item`` Go live on a specific item, by index - + ``servicemanager_list_request`` Request the service list. Responds with servicemanager_list_response containing a array of dictionaries ``maindisplay_blank`` - Blank the maindisplay window + Blank the maindisplay window ``maindisplay_hide`` - Hide the maindisplay window + Hide the maindisplay window ``maindisplay_show`` - Return the maindisplay window + Return the maindisplay window ``maindisplay_active`` The maindisplay has been made active - + ``maindisplay_status_text`` Changes the bottom status bar text on the maindisplay window @@ -193,9 +193,17 @@ class EventReceiver(QtCore.QObject): ``{plugin}_add_service_item`` Ask the plugin to push the selected items to the service item + ``{plugin}_service_load`` + Ask the plugin to process an individual service item after it has been + loaded + + ``service_item_update`` + Passes back to the service manager the service item after it has been + processed by the plugin + ``alerts_text`` Displays an alert message - + ``bibles_nobook`` Attempt to find book resulted in no match diff --git a/openlp/core/lib/htmlbuilder.py b/openlp/core/lib/htmlbuilder.py index 765d0f9fa..511046fe3 100644 --- a/openlp/core/lib/htmlbuilder.py +++ b/openlp/core/lib/htmlbuilder.py @@ -55,14 +55,17 @@ body { background-color: black; display: none; } -#image { +#bgimage { z-index:1; } -#video1 { +#image { z-index:2; } +#video1 { + z-index:3; +} #video2 { - z-index:2; + z-index:3; } #alert { position: absolute; @@ -73,7 +76,7 @@ body { } #footer { position: absolute; - z-index:5; + z-index:6; %s } /* lyric css */ @@ -112,7 +115,7 @@ body { vid2.volume = volume; } switch(state){ - case 'init': + case 'init': vid.src = path; vid2.src = path; if(loop == null) loop = false; @@ -294,7 +297,8 @@ body { - + +