[anjuta-devel] [GCI] Add Python wizard to class-gen plugin



Dear Anjuta developers and mentor Johannes,

As you probably know, I am working on a Python wizard for the class-gen
plugin, and I have a couple of issues I would like to discuss with you.  If
you don't understand what I am talking about, then here's the link of the task
at the GCI task list. [1]

[1] http://www.google-melange.com/gci/task/show/google/gci2010/gnome/t129174942799

First off, I assume after started modifying the code that the original
developer of class-gen didn't have in mind adding support for other languages,
because the use of a header/source file is pretty hard coded into the plugin
at some points and languages like Python/Javascript don't have the concept of
header files, as I am sure you know better than me.
I still haven't written the Python autogen template so I still can't report any
issues with that, but refactorings may be necessary. (I guess that will be
even more necessary when adding support for other languages besides Python).

I will leave the Header and Source File entryboxes as they are at the moment,
until we figure out what the best solution is.


Second, in the class-gen wizard you can specify "Class Elements", for
C++/GObject classes.  Well, what class elements are there for Python?

I've thrown together a short list of possible Python class elements:
  - Class variables

  - Class constants (practically the same as class variable, but as a
    convention in Python you write them in UPPERCASE letters)

  - Class methods (public, pseudoprivate, private, built-ins)

    In Python pseudoprivate methods are the ones who start with a leading
    underscore, but they are not really private, but anyway I'm just citing
    the Python documentation.
    http://docs.python.org/tutorial/classes.html#private-variables

    I'd say a programmer will know what kind of methods he wants, I guess. So
    can I let the "Implementation" column out? Also Implementation sounds
    confusing to me in the case of Python.
    Maybe "Type" would be better?

  - Nested classes
    Now, implementing this sounds scary. Do we need this?

  - Are there any more?

I have attached a patch of my current work to this mail in git-format-patch
style. I started to work off the ANJUTA_2_32_1 tag, because it was recommended
so. Maybe it's good to mention that I have setup a JHBuild environment for
Anjuta. It works for me like that.

That's it for the moment.  I would really appreciate your input, guys.

If there's anything you feel I should know about, please tell me.

Kind regards,
Kenny

-- 
Encouraging respectful discussion with OpenRespect (http://www.openrespect.org)

Attachment: 0001-Add-Python-wizard-to-class-gen-wizard.patch
Description: Text document

Attachment: pgp4NnY9t7frR.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]