Extending Python Questions .....

B

Ben

Ok... Now I can start asking.

In My S-Lag Project called, SLAG, I have some function keys that get
mapped back to S-lang internal functions.

My SLAG project works pretty much like Python (as does the S-Lang).
You write a S-lang script
that "imports" your extension. module - and all this gets run by the
shell/interpreter.

I allow function keys to be mapped back internal function(s) inside of
the controlling program.

My question is which Python C api Do I need to this with ? Do I need
to worry about my reference counting since the Python Program is in
essence calling a function in itself?

Thanks

Ben ...
 
D

Diez B. Roggisch

Ben said:
Ok... Now I can start asking.

In My S-Lag Project called, SLAG, I have some function keys that get
mapped back to S-lang internal functions.

My SLAG project works pretty much like Python (as does the S-Lang).
You write a S-lang script
that "imports" your extension. module - and all this gets run by the
shell/interpreter.

I allow function keys to be mapped back internal function(s) inside of
the controlling program.

My question is which Python C api Do I need to this with ? Do I need
to worry about my reference counting since the Python Program is in
essence calling a function in itself?


What's S-Lag? What is S-Lang?

I'm sure I can google that, however I think you might want to provide a
bit more context yourself to receive better answers.

Diez
 
B

Ben

Do you mean like this?

 http://code.google.com/p/python-slang

Not sure how well maintained it is though.


I'm not sure I understand you here, but in general you don't need to
worry about reference counting in Python - it all happens behind the
scenes.  If you are writing a python extension in C then you do need
to worry about reference counting - a lot!

No, It uses the the S-lang for video, and input control. However, SLAG
is more of an abstract layer on top of that.

It has a Structures that contains menus and screens (menumodule /
screenmodule). One LOADS them up with parameters.
such as creating a new menu is like:

OpenMenu( Company name, SubSystem, this program name, mode, bottom
status display) - Create initial menu structure
Addtomenu(Menu Block Set name, DISPLAY line, ID, type of program,
password ID ) - add to / update MENU blocks.
runMenu() - Displays the whole create menu structure.

The Menu structure is done in pull downs and scrollable blocks in a
TUI (text User Interface) and using the
S-lang screen library is fully mouseable.

The screen module works mych the same way, but with the abiltity to
open and close and
work within "Sub Screens".


For those who do not know, S-lang is a interpreted language much like
Python. However, there
is s direth of library modules. The original S-lang started out as
library of screen of keyboard
modules, but has been expanded

My SLAG project does not care in reality WHICH or what language, it is
simply handling menu and
screen control.

Hope this helps ...
 
B

Ben

So do you want to embed python into your code?

I'm still not clear what you are trying to achieve with python, though
I have a better idea what SLAG is now!

Actually no, I want to EXTEND python using the lower levels of S-lang
screen modules.

My Modules are written in C and are a frame work for building pull-
down menus and data entry screens.

Very nice for writing business applications. Think along the lines of
FoxPro and/or the
"Screen" section in Cobol and you have a pretty good idea of what i
have done.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top