paulb@11 | 1 | Introduction
|
paulb@11 | 2 | ------------
|
paulb@11 | 3 |
|
paul@68 | 4 | The desktop package provides desktop environment detection and resource
|
paul@68 | 5 | opening support for a selection of common and standardised desktop
|
paul@68 | 6 | environments.
|
paulb@20 | 7 |
|
paul@68 | 8 | Currently, in Python's standard library, there is apparently no coherent,
|
paul@68 | 9 | cross-platform way of getting the user's environment to "open" files or
|
paul@68 | 10 | resources (showing such files in browsers or editors, for example) when
|
paul@68 | 11 | requested by a Python program. There is an os.startfile function which works
|
paul@68 | 12 | for Windows, but no equivalent function for other desktop environments - the
|
paul@68 | 13 | webbrowser module seems to employ alternative mechanisms in choosing and
|
paul@68 | 14 | running external programs and presumably does not seek to provide general
|
paul@68 | 15 | support for non-URL resources anyway.
|
paul@68 | 16 |
|
paul@68 | 17 | Since desktop environments like KDE and GNOME provide mechanisms for running
|
paul@68 | 18 | browsers and editors according to the identified type of a file or resource,
|
paul@68 | 19 | just as Windows "runs" files or resources, it is appropriate to have a module
|
paul@68 | 20 | which accesses these mechanisms. It is this kind of functionality that the
|
paul@68 | 21 | desktop package aims to support. Note that this approach is arguably better
|
paul@68 | 22 | than that employed by the webbrowser module since most desktop environments
|
paul@68 | 23 | already provide mechanisms for configuring and choosing the user's preferred
|
paul@68 | 24 | programs for various activities, whereas the webbrowser module makes
|
paul@68 | 25 | relatively uninformed guesses (for example, opening Firefox on a KDE desktop
|
paul@68 | 26 | configured to use Konqueror as the default browser).
|
paulb@11 | 27 |
|
paulb@33 | 28 | Some ideas for desktop detection (XFCE) and URL opening (XFCE, X11) were
|
paulb@33 | 29 | obtained from the xdg-utils project which seeks to implement programs
|
paulb@33 | 30 | performing similar functions to those found in the desktop module. The
|
paulb@33 | 31 | xdg-utils project can be found here:
|
paulb@33 | 32 |
|
paulb@33 | 33 | http://portland.freedesktop.org/
|
paulb@33 | 34 |
|
paulb@33 | 35 | Other information regarding desktop icons and menus, screensavers and MIME
|
paulb@33 | 36 | configuration can also be found in xdg-utils.
|
paulb@33 | 37 |
|
paulb@11 | 38 | Contact, Copyright and Licence Information
|
paulb@11 | 39 | ------------------------------------------
|
paulb@11 | 40 |
|
paulb@11 | 41 | No Web page has yet been made available for this work, but the author can be
|
paulb@11 | 42 | contacted at the following e-mail address:
|
paulb@11 | 43 |
|
paulb@11 | 44 | paul@boddie.org.uk
|
paulb@11 | 45 |
|
paulb@11 | 46 | Copyright and licence information can be found in the docs directory - see
|
paul@68 | 47 | docs/COPYING.txt, docs/lgpl-3.0.txt and docs/gpl-3.0.txt for more information.
|
paulb@11 | 48 |
|
paulb@11 | 49 | Notes
|
paulb@11 | 50 | -----
|
paulb@11 | 51 |
|
paulb@4 | 52 | Notes on desktop application/environment support:
|
paulb@4 | 53 |
|
paulb@4 | 54 | KDE Supports file and URL opening using kfmclient, where the openURL
|
paulb@4 | 55 | command opens the resource and the exec command runs the
|
paulb@4 | 56 | resource.
|
paulb@4 | 57 |
|
paul@73 | 58 | KDE 4 Similar to KDE but uses kioclient instead of kfmclient.
|
paul@73 | 59 |
|
paulb@4 | 60 | GNOME Supports file and URL opening using gnome-open.
|
paulb@4 | 61 |
|
paulb@33 | 62 | XFCE Supports file and URL opening using exo-open.
|
paulb@33 | 63 |
|
paulb@4 | 64 | ROX-Filer Supports file opening using "rox <filename>" but not URL
|
paulb@4 | 65 | opening.
|
paulb@17 | 66 |
|
paul@84 | 67 | New in desktop 0.4.3 (Changes since desktop 0.4.2)
|
paul@84 | 68 | --------------------------------------------------
|
paul@84 | 69 |
|
paul@84 | 70 | * Added missing KDE 4 support to the desktop.dialog module.
|
paul@84 | 71 |
|
paul@78 | 72 | New in desktop 0.4.2 (Changes since desktop 0.4.1)
|
paul@78 | 73 | --------------------------------------------------
|
paul@78 | 74 |
|
paul@78 | 75 | * Added XFCE 4.10 "mailto:" fix contributed by Jérôme Laheurte.
|
paul@78 | 76 |
|
paul@73 | 77 | New in desktop 0.4.1 (Changes since desktop 0.4)
|
paul@73 | 78 | ------------------------------------------------
|
paul@73 | 79 |
|
paul@73 | 80 | * Added KDE 4 and Lubuntu support contributed by Jérôme Laheurte.
|
paul@73 | 81 |
|
paul@68 | 82 | New in desktop 0.4 (Changes since desktop 0.3)
|
paul@68 | 83 | ----------------------------------------------
|
paulb@60 | 84 |
|
paulb@60 | 85 | * Improved docstrings.
|
paulb@60 | 86 | * Fixed support for examining the root window.
|
paul@68 | 87 | * Changed the licence to the LGPL version 3 (or later).
|
paulb@60 | 88 |
|
paulb@54 | 89 | New in desktop 0.3 (Changes since desktop 0.2.4)
|
paulb@54 | 90 | ------------------------------------------------
|
paulb@54 | 91 |
|
paulb@54 | 92 | * Made desktop a package.
|
paulb@54 | 93 | * Added support for graphical dialogue boxes through programs such as
|
paulb@54 | 94 | kdialog, zenity and Xdialog.
|
paulb@54 | 95 | * Added support for inspecting desktop windows (currently only for X11).
|
paulb@54 | 96 |
|
paulb@33 | 97 | New in desktop 0.2.4 (Changes since desktop 0.2.3)
|
paulb@33 | 98 | --------------------------------------------------
|
paulb@33 | 99 |
|
paulb@40 | 100 | * Added XFCE support (with advice from Miki Tebeka).
|
paulb@36 | 101 | * Added Ubuntu Feisty (7.04) package support.
|
paulb@33 | 102 |
|
paulb@27 | 103 | New in desktop 0.2.3 (Changes since desktop 0.2.2)
|
paulb@27 | 104 | --------------------------------------------------
|
paulb@27 | 105 |
|
paulb@27 | 106 | * Added Python 2.3 support (using popen2 instead of subprocess).
|
paulb@27 | 107 |
|
paulb@24 | 108 | New in desktop 0.2.2 (Changes since desktop 0.2.1)
|
paulb@24 | 109 | --------------------------------------------------
|
paulb@24 | 110 |
|
paulb@24 | 111 | * Changed the licence to LGPL.
|
paulb@24 | 112 |
|
paulb@20 | 113 | New in desktop 0.2.1 (Changes since desktop 0.2)
|
paulb@20 | 114 | ------------------------------------------------
|
paulb@20 | 115 |
|
paulb@20 | 116 | * Added Debian/Ubuntu package support.
|
paulb@20 | 117 |
|
paulb@17 | 118 | New in desktop 0.2 (Changes since desktop 0.1)
|
paulb@17 | 119 | ----------------------------------------------
|
paulb@17 | 120 |
|
paulb@18 | 121 | * Added support for waiting for launcher processes.
|
paulb@17 | 122 | * Added a tests directory.
|
paulb@20 | 123 |
|
paulb@20 | 124 | Release Procedures
|
paulb@20 | 125 | ------------------
|
paulb@20 | 126 |
|
paulb@20 | 127 | Update the desktop __version__ attribute.
|
paulb@20 | 128 | Change the version number and package filename/directory in the documentation.
|
paulb@20 | 129 | Update the release notes (see above).
|
paulb@20 | 130 | Update the package information.
|
paulb@20 | 131 | Check the release information in the PKG-INFO file.
|
paulb@20 | 132 | Check the setup.py file.
|
paulb@20 | 133 | Tag, export.
|
paulb@20 | 134 | Archive, upload.
|
paul@65 | 135 | Update PyPI entry.
|
paulb@20 | 136 |
|
paulb@20 | 137 | Making Packages
|
paulb@20 | 138 | ---------------
|
paulb@20 | 139 |
|
paulb@20 | 140 | To make Debian-based packages:
|
paulb@20 | 141 |
|
paulb@20 | 142 | 1. Create new package directories under packages if necessary.
|
paul@81 | 143 |
|
paulb@20 | 144 | 2. Make a symbolic link in the distribution's root directory to keep the
|
paulb@20 | 145 | Debian tools happy:
|
paulb@20 | 146 |
|
paul@81 | 147 | ln -s packages/debian-wheezy/python-desktop/debian/
|
paulb@20 | 148 |
|
paulb@20 | 149 | 3. Run the package builder:
|
paulb@20 | 150 |
|
paulb@20 | 151 | dpkg-buildpackage -rfakeroot
|
paulb@20 | 152 |
|
paul@81 | 153 | Or:
|
paul@81 | 154 |
|
paul@81 | 155 | pdebuild
|
paul@81 | 156 |
|
paulb@20 | 157 | 4. Locate and tidy up the packages in the parent directory of the
|
paulb@20 | 158 | distribution's root directory.
|