Linux X11 Framework (X Windows System for FreeBASIC)
-
- Posts: 8586
- Joined: May 28, 2005 3:28
- Contact:
Linux X11 Framework (X Windows System for FreeBASIC)
I have ported over 600 protoytypes as an "x11.bi" FreeBASIC include file.
download: fbX11.zip
Attention
I have many tested not all 600.
Please report any "X11.bi" releated problems here.
Thanks Joshy
download: fbX11.zip
Attention
I have many tested not all 600.
Please report any "X11.bi" releated problems here.
Thanks Joshy
Last edited by D.J.Peters on Jul 19, 2011 1:43, edited 5 times in total.
Are you doing the translation by hand? Let SWIG do it, the headers will be translated in seconds.
Btw, the "convention" now is to use "ByVal SomeName As SomeType Ptr" and not "ByRef SomeName As SomeType" in function prototypes. Byref params make pointers too error prone to work with and "@sometype" makes more sense than "byval someptr" and you will be sure no different pointer types are been passed - the byval modifier turns off any checking.
Btw, the "convention" now is to use "ByVal SomeName As SomeType Ptr" and not "ByRef SomeName As SomeType" in function prototypes. Byref params make pointers too error prone to work with and "@sometype" makes more sense than "byval someptr" and you will be sure no different pointer types are been passed - the byval modifier turns off any checking.
Great work
Great work and thanks alot DJ Peters
-
- Posts: 8586
- Joined: May 28, 2005 3:28
- Contact:
Yes it is made by hand from the include files from my own Linux Basic Compiler GAMEBASM.v1ctor wrote:Are you doing the translation by hand? Let SWIG do it, the headers will be translated in seconds...
I have make an try with the swig tool on a windows partition but x.h xlib.h and xutil.h is not independet and many macros are wrong with this tools (or my wrong usage of swig) and all comments and useful hints / infos are gone with swig.
I use the "x11.bi" file in the next X11 FreeBASIC lessons and all wrong declares will be fixed.
After it you can put it to the FreeBASIC package if you will.
Joshy
Curently only a handful declares are litle bugy.
Last edited by D.J.Peters on Apr 19, 2007 22:11, edited 1 time in total.
-
- Posts: 85
- Joined: Jun 18, 2006 19:48
His server URL changed slightly, use:
http://www.alice-dsl.net/d.j.peters/libs/X11.bi
-tested, working.
http://www.alice-dsl.net/d.j.peters/libs/X11.bi
-tested, working.
-
- Posts: 8586
- Joined: May 28, 2005 3:28
- Contact:
-
- Posts: 2428
- Joined: Jul 19, 2006 19:17
- Location: Sunnyvale, CA
- Contact:
Are you using any .htaccess files? I'm forcing the "www" to disappear with this:D.J.Peters wrote:my ISP changed something
now all my links need www in front
i don't know why it is.
Code: Select all
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^kristopherw.us$ [NC]
RewriteRule ^(.*)$ http://kristopherw.us/$1 [L,R=301]
-
- Posts: 42
- Joined: Aug 03, 2009 22:42
Houston, we have a problem.http://www.freebasic.net/forum/viewtopi ... 27#152827
any ideas?
any ideas?
Hi D.J.Peters,
FBC version 0.22.0 (05-06-2011) for linux (target:linux)
Getting some errors when i include your x11.bi in a simple testing program:
#include "/KNOPPIX-DATA/usr/include/freebasic/X11.bi"
?"test"
sleep
end
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(2888) error 56: Illegal specification, at parameter 13 ()) of XGetWindowProperty() in ') as integer'
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(3523) error 56: Illegal specification, at parameter 3 (colord) of XStoreColors() in 'byval colord as XCOLORptr, _'
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(3949) error 7: Expected ')', found 'byval' in 'byval name_len as integer , _'
Can you help me with this one?
Thanx
Well, I am having some problems with x11.bi under KNOPPIX.Please report any "X11.bi" releated problems here.
FBC version 0.22.0 (05-06-2011) for linux (target:linux)
Getting some errors when i include your x11.bi in a simple testing program:
#include "/KNOPPIX-DATA/usr/include/freebasic/X11.bi"
?"test"
sleep
end
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(2888) error 56: Illegal specification, at parameter 13 ()) of XGetWindowProperty() in ') as integer'
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(3523) error 56: Illegal specification, at parameter 3 (colord) of XStoreColors() in 'byval colord as XCOLORptr, _'
/KNOPPIX-DATA/usr/include/freebasic/X11.bi(3949) error 7: Expected ')', found 'byval' in 'byval name_len as integer , _'
Can you help me with this one?
Thanx
Rens, there appears to be an extra comma at X11.bi(2887), a missing comma at X11.bi(3948) and at X11.bi(3523) it should be 'XCOLOR ptr' instead of 'XCOLORptr'.
After these fixes it seems to work with FB 0.22 despite being from 2005. There also are some X11 headers at http://code.google.com/p/freebasic-head ... Finc%2FX11, though I don't know whether there are differences.
After these fixes it seems to work with FB 0.22 despite being from 2005. There also are some X11 headers at http://code.google.com/p/freebasic-head ... Finc%2FX11, though I don't know whether there are differences.
The difference is the x11 headers there are machine translated only. I haven't had the chance to go through them to correct anything or format them how they should be. The advantage though is you don't have a huge include file slowing down compilation and errors in the headers will be easy to isolate. If anyone finds errors in them they can post it on the issue page there (req google acct) or can shoot me an email using the form at http://mud.owlbox.net
-
- Posts: 1008
- Joined: Nov 24, 2011 19:49
- Location: France
- Contact:
Re: Linux X11 Framework (X Windows System for FreeBASIC)
Hello Joshy!
Is is still possible to get your X11 package?
Regards.
Roland
Is is still possible to get your X11 package?
Regards.
Roland