poelzi / pida-poelzi-newbuffer

fork of pida-main

this is an experimental, long living branch for 0.7 most likely. it's a complete redesign of the core<->editor interface. goals: - editors will require dbus, direct embedding or a similar technique which must be able to control the editor from background - cleaner api - support for split views. one buffer on different views etc. (at least from the api side it's possible)

Changed (Δ2.2 KB):

raw changeset »

.hgignore (2 lines added, 0 lines removed)

MANIFEST.in (9 lines added, 4 lines removed)

pida/__init__.py (9 lines added, 17 lines removed)

pida/core/application.py (5 lines added, 5 lines removed)

pida/services/bugreport/bugreport.py (2 lines added, 2 lines removed)

pida/services/commander/commander.py (2 lines added, 2 lines removed)

pida/services/help/help.py (11 lines added, 10 lines removed)

pida/services/plugins/plugins.py (0 lines added, 1 lines removed)

setup.py (38 lines added, 12 lines removed)

Up to file-list .hgignore:

@@ -16,3 +16,5 @@ tmp
16
16
.pida-metadata
17
17
.*\.*~
18
18
externals
19
dist
20
MANIFEST

Up to file-list MANIFEST.in:

@@ -4,12 +4,17 @@ include COPYING
4
4
include INSTALL
5
5
include CHANGELOG
6
6
include README
7
recursive-include pida *
8
recursive-include pida-plugins *
7
8
recursive-include pida *.py *.glade *.xml *.po *.png *.el *.vim *.gif *.svg *.pida *.xpm
9
recursive-include pida-plugins *.py *.glade *.xml *.po *.png *.el *.vim *.gif *.svg *.pida *.xpm
9
10
recursive-include contrib *
10
recursive-include tests *
11
recursive-include moo *
11
recursive-include tests *.py
12
12
recursive-include bin *
13
13
recursive-include tools *
14
14
recursive-include docs *
15
15
16
prune pida/ui/moo_stub.so
17
prune contrib/moo/marshals.*
18
prune contrib/moo/stock-moo.h
19
prune contrib/moo/moo-pygtk.c
20

Up to file-list pida/__init__.py:

2
2
The Python Integrated Development Application IDE Framework
3
3
"""
4
4
5
PIDA_VERSION = '0.6.0'
5
version = '0.6beta1'
6
6
7
PIDA_NAME = 'PIDA'
7
copyright = 'Copyright (c) 2005-2008 The PIDA Project'
8
8
9
PIDA_COPYRIGHT = 'Copyright (c) 2005-2008 The PIDA Project'
9
website = 'http://pida.co.uk/'
10
10
11
PIDA_WEBSITE = 'http://pida.co.uk/'
11
author = 'Ali Afshar <aafshar@gmail.com>'
12
12
13
PIDA_AUTHOR = 'Ali Afshar <aafshar@gmail.com>'
13
maintainer = author
14
14
15
PIDA_MAINTAINER = PIDA_AUTHOR
16
17
PIDA_AUTHORS = [PIDA_AUTHOR] + [
15
authors = [
16
    author,
18
17
    'Tiago Cogumbreiro <cogumbreiro@users.sf.net>',
19
18
    'Alejandro Mery <amery@geeks.cl>',
20
19
    'Bernard Pratz <guyzmo@m0g.net>',
@@ -25,15 +24,8 @@ PIDA_AUTHORS = [PIDA_AUTHOR] + [
25
24
    'Alexander Gabriel <Alexander.Gabriel@TU-Harburg.de>',
26
25
    'Tobias Eberle <info@tobiaseberle.de>',
27
26
    'Daniel Poelzleithner <pida@poelzi.org>'
27
    #XXX: khiraly
28
28
]
29
29
30
PIDA_SHORT_DESCRIPTION = 'An integrated development environment that reuses tools such as Vim, and all version control systems.'
30
short_description = 'An integrated development environment that reuses tools such as Vim, and all version control systems.'
31
31
32
PIDA_LICENSE = """
33
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
34
35
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
36
37
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
38
"""
39

Up to file-list pida/core/application.py:

@@ -65,16 +65,16 @@ if sys.version_info < (2, 5):
65
65
66
66
# This can test if PIDA is installed
67
67
try:
68
    from pida.core.environment import opts, on_windows
69
    from pida.core.boss import Boss
70
    from pida import PIDA_VERSION
71
68
    import pida
72
69
except ImportError, e:
73
70
    die_gui(_('The pida package could not be found.'), e)
74
71
75
72
# we have to import pdbus here so it gets initialized very early
76
73
import pida.core.pdbus
77
74
75
from pida.core.environment import opts, on_windows
76
from pida.core.boss import Boss
77
78
78
def run_pida():
79
79
    b = Boss()
80
80
@@ -193,7 +193,7 @@ def main():
193
193
                        'Not all functions available.', Warning, 'pida', '')
194
194
        
195
195
    if opts.version:
196
        print _('PIDA, version %s') % PIDA_VERSION
196
        print _('PIDA, version %s') % pida.version
197
197
    elif opts.profile_path:
198
198
        print "---- Running in profile mode ----"
199
199
        import hotshot, hotshot.stats, test.pystone

Up to file-list pida/services/bugreport/bugreport.py:

@@ -11,7 +11,7 @@ import gobject
11
11
12
12
13
13
# PIDA Imports
14
from pida import PIDA_VERSION
14
import pida
15
15
16
16
from pida.core.service import Service
17
17
from pida.core.features import FeaturesConfig
@@ -65,7 +65,7 @@ class BugreportView(PidaGladeView):
65
65
        title = self.title_entry.get_text()
66
66
        buf = self.description_text.get_buffer()
67
67
        description = buf.get_text(buf.get_start_iter(), buf.get_end_iter())
68
        description = 'PIDA %s\n--\n%s' % (PIDA_VERSION, description)
68
        description = 'PIDA %s\n--\n%s' % (pida.version, description)
69
69
        return report(None, self.email, self.password, 'pida', title, description)
70
70
71
71
    def report_complete(self, success, data):

Up to file-list pida/services/commander/commander.py:

@@ -12,6 +12,7 @@ import gobject
12
12
import pango
13
13
14
14
# PIDA Imports
15
import pida
15
16
from pida.core import environment
16
17
from pida.core.service import Service
17
18
from pida.core.features import FeaturesConfig
@@ -20,7 +21,6 @@ from pida.core.events import EventsConfi
20
21
from pida.core.actions import ActionsConfig
21
22
from pida.core.options import OptionsConfig
22
23
from pida.core.actions import TYPE_NORMAL, TYPE_MENUTOOL, TYPE_RADIO, TYPE_TOGGLE
23
from pida import PIDA_VERSION
24
24
25
25
from pida.utils.gthreads import AsyncTask
26
26
@@ -577,7 +577,7 @@ class Commander(Service):
577
577
    def execute(self, commandargs, env, cwd, title, icon, eof_handler=None,
578
578
                use_python_fork=False, parser_func=None):
579
579
        env_pida = env
580
        env_pida.append('PIDA_VERSION=%s' % PIDA_VERSION)
580
        env_pida.append('PIDA_VERSION=%s' % pida.version)
581
581
        current_project = self.boss.cmd('project', 'get_current_project')
582
582
        if current_project:
583
583
            env_pida.append('PIDA_PROJECT=%s' % current_project.source_directory)

Up to file-list pida/services/help/help.py:

@@ -8,6 +8,7 @@ import gtk
8
8
from gtk import gdk
9
9
10
10
# PIDA Imports
11
import pida
11
12
from pida.core.service import Service
12
13
from pida.core.features import FeaturesConfig
13
14
from pida.core.commands import CommandsConfig
@@ -17,9 +18,6 @@ from pida.core.actions import TYPE_NORMA
17
18
18
19
from pida.core.environment import get_pixmap_path
19
20
20
from pida import PIDA_NAME, PIDA_VERSION, PIDA_AUTHORS, PIDA_COPYRIGHT, \
21
                 PIDA_LICENSE, PIDA_WEBSITE, PIDA_SHORT_DESCRIPTION
22
23
21
24
22
# locale
25
23
from pida.core.locale import Locale
@@ -31,15 +29,18 @@ class PidaAboutDialog(gtk.AboutDialog):
31
29
    def __init__(self, boss):
32
30
        gtk.AboutDialog.__init__(self)
33
31
        self.set_transient_for(boss.window)
34
        self.set_name(PIDA_NAME)
35
        self.set_version(PIDA_VERSION)
32
        self.set_name('pida')
33
        self.set_version(pida.version)
36
34
        self.set_logo(self._create_logo())
37
        self.set_copyright(PIDA_COPYRIGHT)
38
        self.set_license(PIDA_LICENSE)
35
        self.set_copyright(pida.copyright)
36
        self.set_license(
37
            'GNU GPL Version 2 (or at your choice any later) '
38
             'as published by the FSF'
39
        )
39
40
        self.set_wrap_license(True)
40
        self.set_authors(PIDA_AUTHORS)
41
        self.set_website(PIDA_WEBSITE)
42
        self.set_comments(PIDA_SHORT_DESCRIPTION)
41
        self.set_authors(pida.authors)
42
        self.set_website(pida.website)
43
        self.set_comments(pida.short_description)
43
44
44
45
    def _create_logo(self):
45
46
        pb = gdk.pixbuf_new_from_file_at_size(

Up to file-list pida/services/plugins/plugins.py:

@@ -28,7 +28,6 @@ import shutil
28
28
import pida.plugins
29
29
30
30
from kiwi.ui.objectlist import Column
31
from pida import PIDA_VERSION
32
31
from pida.ui.views import PidaGladeView
33
32
from pida.core.commands import CommandsConfig
34
33
from pida.core.service import Service

Up to file-list setup.py:

@@ -3,14 +3,15 @@ The PIDA Installer
3
3
"""
4
4
5
5
import os
6
import subprocess
7
import sys
8
6
9
from distutils.core import setup, Extension
7
10
from distutils.command.build_ext import build_ext
8
11
9
from pida import PIDA_VERSION, PIDA_AUTHOR, PIDA_WEBSITE, \
10
                 PIDA_SHORT_DESCRIPTION, PIDA_NAME
12
import pida
11
13
12
14
# Check availability of pygtk 2.0
13
import subprocess, sys
14
15
NO_PYGTK_ERROR_MESSAGE = """pkg-config reports your system misses pygtk 2.0.
15
16
PIDA needs pygtk headers at compile time. These can generally be found in the
16
17
python-dev or python-gtk2-dev package of your distribution.
@@ -42,8 +43,9 @@ moo = Extension(
42
43
class BuildExt(build_ext):
43
44
    def build_extension(self, ext):
44
45
        if ext.name == 'pida.ui.moo_stub':
45
            if os.system('cd contrib/moo && make prepare'):
46
                raise RuntimeError()
46
            subprocess.check_call(['make', 'prepare'],
47
                cwd=os.path.join(os.path.dirname(__file__),'contrib/moo')
48
            )
47
49
        build_ext.build_extension(self, ext)
48
50
49
51
@@ -99,17 +101,41 @@ all_package_data = get_main_data()
99
101
all_packages = list_pida_packages() + list_pida_services(all_package_data)
100
102
101
103
setup(
102
    name = PIDA_NAME,
103
    version = PIDA_VERSION,
104
    name = 'pida',
105
    version = pida.version,
104
106
    packages = all_packages,
105
107
    package_data = all_package_data,
106
108
    ext_modules = [moo],
107
109
    cmdclass={'build_ext': BuildExt},
108
110
    scripts=['bin/pida', 'bin/pida-remote', 'bin/pida-build', 'bin/pida-pyshell'],
109
    author = PIDA_AUTHOR,
110
    author_email = PIDA_AUTHOR,
111
    url = PIDA_WEBSITE,
112
    download_url = PIDA_WEBSITE + 'download/',
113
    description = PIDA_SHORT_DESCRIPTION,
111
    author = pida.author,
112
    author_email = pida.author,
113
    url = pida.website,
114
    download_url = pida.website + 'download/',
115
    description = pida.short_description,
116
    classifiers = [
117
        'Development Status :: 4 - Beta',
118
        'Environment :: X11 Applications :: GTK',
119
        'Intended Audience :: Developers',
120
        'License :: OSI Approved :: GNU General Public License (GPL)',
121
        'Operating System :: POSIX :: Linux',
122
        'Operating System :: POSIX :: BSD',
123
        'Operating System :: Microsoft :: Windows :: Windows NT/2000',
124
        'Topic :: Software Development',
125
        'Topic :: Software Development :: Version Control',
126
        'Topic :: Text Editors',
127
        'Topic :: Utilities',
128
    ],
129
    requires = [
130
        #XXX: more ?
131
        'anyvc (>= 0.2)',
132
        'simplejson',
133
        'PyGtk (>= 2.14)',
134
        #'kiwi-gtk (>= 1.9.23)', #XXX distutils doesnt like the -
135
        #'vte',
136
        #'dbus ?',
137
        #'rope ?',
138
        #'moo ?'
139
    ]
114
140
)
115
141