Hi all,
(I appologise if this is not exactly the right place to ask,) are there any fpc projects/examples/demos/whatever using x11 units rather than wrapping to some toolkits?
I've looked through contribs and found none.
Any hints or refs appreciated.
Mailing lists / fpc-pascal / 2002-07
Any examples using x11 units?
6 messages · 3 people · –
- AAnton Tichawa 2
- GGeorgi Georgiev 2
- NNikolai Zhubr 2
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
I'm traing to test if there is some input
bytes ready in stdin. When i try this with normal
file, all is ok - SelectText function from Linux unit give me n>0 if any character is ready.
When i try with file 'input', SelectText give me 0 until 2 lines are entered. How to go round this
without using old and more low-level libs like crt ?
------- test program -------
program test;
uses Linux;
var n:longint; w:char; TV:TimeVal;
begin
TV.sec:=0; TV.usec:=0;
repeat
n:=SelectText(input,@TV);
if n>0 then begin
read(w); write(w);
write('[',n,']');
end;
until eof(input);
end.--------- test results: ----------
1234
abcd
1[1]2[1]3[1]4[1]
[1]ABCD
a[1]b[1]c[1]d[1]
[1]
--------- must be: ---------------
1234
1[1]2[1]3[1]4[1]
[1]abcd
a[1]b[1]c[1]d[1]
[1]ABCD
----------------------------------
=====
Skelet
====== http://skelet.hit.bg
__________________________________________________ Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com
(I appologise if this is not exactly the right place to ask,) are there any fpc…
hello,
I've written a small example program that opens a window, displays a rotating line, listens for mouse movement and keyboard messages and displays mouse positions and key codes. The program uses (imports) just X, Xlib, and Linux.
I have not yet included timers, so I still use delays, and the program consumes much of the CPU performance.
If you want to have a copy, just send me an email.
Best regards,
Anton Tichawa
you wrote 6 lines
I'm traing to test if there is some input bytes ready in stdin. When i try this with…
hello,
you can use 'select', look at the man page.
hth,
Anton Tichawa
you wrote 59 lines
I've written a small example program that opens a window, displays a rotating line,…
Hi,
Anton Tichawa wrote 5 lines
Ok. Thanks for replying.
I've just finished something like that, but even simpler. Approx one page of code. (I mean, it also works ;)
And, it looks like xlib.pp is not quite valid. For example, TXPointer is used almost everywhere instead of PXPointer, which breaks stuff. As far as I understood, x11 package is pure autotranslated, so no big surprise. I just wonder how do people use it?
Question 1: Is anyone going to fix it?
Question 2: If no, should I submit patches?
you can use 'select', look at the man page. Anton Tichawa
--- Anton Tichawa wrote: >
hello,
you can use 'select', look at the man page.
For file 'input' effect is the same - select
return nonzero value after the second Enter !
Show quoted text 11 lines
=====
Skelet
====== http://skelet.hit.bg
__________________________________________________ Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com
