FYI
i found a link containing most of the reference manuals (for linux users)
here
bye
varun
User Profile
Collapse
-
-
every thing seems to be correct
have you installed pygobject and pygtk as given below, if so it should work.
1. cd pygobject && ./configure --prefix=$PREFIX PYTHON=pythonx. x && make && make install
(x.x is version of python currently installed)
2. cd pygtk && ./configure --prefix=$PREFIX PYTHON=pythonx. x && make && make install...Leave a comment:
-
search for .override file in the MPI source code, open it and search for "ignore" field, under that field write MPI_Get_version
it will be something like this
%%
ignore
......<some function name>
....
MPI_Get_version ----->>> add like this
%%
give a try...Leave a comment:
-
can you post what r the steps you have taken to install pygtk....Leave a comment:
-
Bvdet is Correct.
Try prefixing tab on following lines
...Code:# # make a guess guess = tree.getCargo() prompt = "Is it a " + guess + "? " if yes(prompt): print "I rule!" continue # get new information prompt = "What is the animal's name? " animal = raw_input(prompt) promptLeave a comment:
-
hi
sorry for the late responce
i think you need to manually write for (int argc,char *argv[])
try this code in your .i file
...Code:%typemap(in) (int argc, char *argv[]) { int i; if (!PyList_Check($input)) { PyErr_SetString(PyExc_ValueError, "Expecting a list"); return NULL; } $1 = PyList_Size($input); $2 = (char **) malloc(($1+1)*sizeof(charLeave a comment:
-
only post lines of function
SWIG_wrap_main( ...) or something like that...Leave a comment:
-
how to call a method of GtkWidget by using object of GtkWindow in python
hi
as we know that in gtk programming i can call API of a GtkWidget using
an object of GtkWindow by use of type casting MACROS
ie
i can do as
but in python i can't do this because GtkWindow has its own method gtk_window_show (), so whenever i do window.show()Code:GtkWindow *window=gtk_window_new(); .... .... gtk_widget_show(GTK_WIDGET(window));
gtk_window_show () will... -
-
hi
first install python2.5 as ./configure && make && make install
than install your pyMDI-2.4b4 as ./configure PYTHON=python2. 5 && make && make install or what ever is there in README file but configure using PYTHON variable
than from terminal run
$ python2.5
>>> import mpi
it should run...Leave a comment:
-
this is really weired, i have no idea about this, may be someone will post a solution or you can post the solution before anyone does....Leave a comment:
-
how r u compiling your script. May be there lies a problem?
I tried this compile.py script
and than changed the permission and it worked...Code:!#/usr/bin/env python import py_compile py_compile.compile("MyScript.py")Leave a comment:
-
hi r035198x
good to see you moving to linux, i m sure you will love it.
check Ubuntu Feisty 7.04, its more friendly than Fedora
you can order the CDs from https://shipit.ubuntu.com/
first register yourself (link will be displayed on top right corner)
its free of cost and they will deliver at your doorsteps.
bye
varun...Leave a comment:
-
hi
try changing permission of the .pyc file using
and also first line of the script should beCode:sudo chmod +x MyScript.pyc
!#/usr/bin/env python...Leave a comment:
-
hi
replying to myself..
i consulted authors of pygtk group and the information they provided is
h2def.py never generate scheme as define-interface, they generate it as define-objects. You need to manually edit it.
Also You could try defsgen.py:
http://svn.gnome.org/viewcvs/pygtk/t...en.py?view=log
which uses ctypes to generate .defs - its more comprehensive...Leave a comment:
-
i figured out the problem. I thought, i followed code writing standard of Gtk, but not i did some mistake and the .defs file generator (h2def.py) was unable to generate the "scheme" for interface (GTypeInterface ) (i have to still figure that out). But i edited directly the generated .defs file.
Generated scheme for my interface looked like
...Code:;; -*- scheme -*- ; object definitions ... (define-objectLeave a comment:
-
Extending python to our own gtk inherited Widgets
hi
i extended python to my own widgets inherited from gtk.
But when i try to run command
it displays following errorCode:python2.5 -c "import mygtk"
...Code:"TypeError: mro() returned base with unsuitable layout ('gtkmy.MyChoice')" ... .. "** (-c:13962): WARNING **: couldn't make the type `gtkmy.MyList' ready" "TypeError: multiple bases have instance -
i think "Vector c" is a local variable, so make it as "Vector *c" and function definition as
and call the function asCode:double sum(Vector *c) { return (c->x+c->y+c->z); }
Vector a;
sum(&a);
bye...Leave a comment:
No activity results to display
Show More
Leave a comment: