nanogui@linuxhacker.org

nanogui@linuxhacker.org


Subject: Improved keyboard event handler and mouse motion event handler for flnx
From: mateng
Date: Mon, 27 Nov 2000 09:39:44 +0800

Hi Greg and others,
    We are now working with microwindows-0.89pre5 and flnx-0.14.
    Thank you for your great work that many problems were solved in these two newest
released version.
    But keyboard events processor is still incomplete and needs more work to be done.
When press some special key(such as F10), a sequence of key press events is generated
by nano-X. If we use a Fl_Input widget, it will result in a string as "[21~".
    I did some work to solve this problem. All work is done in the flnx source file
<Fl_x.cxx>. New added or modified code is marked with "MaTeng".
    It is a simple but unperfect way. I just handle the keyboard press event. When meet
special key, I record its string and match it in a key-map array, then forward. Now
it seems work well.
    I met another problem. When use framebuffer, the demo program scroll.cxx seems to
be very inefficent while draging the scrollbar. The refresh rate is too slow. I made
some modification to the method fl_wait() to filter the mouse motion event. Now, it
looks better but still can not meet our needs. How can I solve this problem? 
    The last problem is after pressing CTRL_C in flnx demo program editor, I can not
get keypress event any more from the nano-X server. I had to stop nano-X and restart
it.
    Since I am not familiar with nano-X, I think my modification is incomplete and maybe
there is some other better way. Your advice will be very important and useful to me.
    By the way, I am glad to commit my modification and wish it will do you good.
    The attachment is a winzip archive file.

Best regards!

MaTeng<tengma@redflag-linux.com>
P.R.China


Hi Greg and others,
    We are now working with microwindows-0.89pre5 and flnx-0.14.
    Thank you for your great work that many problems were solved in these two newest released version.
    But keyboard events processor is still incomplete and needs more work to be done. When press some special key(such as F10), a sequence of key press events is generated by nano-X. If we use a Fl_Input widget, it will result in a string as "[21~".
    I did some work to solve this problem. All work is done in the flnx source file <Fl_x.cxx>. New added or modified code is marked with "MaTeng".
    It is a simple but unperfect way. I just handle the keyboard press event. When meet special key, I record its string and match it in a key-map array, then forward. Now it seems work well.
    I met another problem. When use framebuffer, the demo program scroll.cxx seems to be very inefficent while draging the scrollbar. The refresh rate is too slow. I made some modification to the method fl_wait() to filter the mouse motion event. Now, it looks better but still can not meet our needs. How can I solve this problem?
    The last problem is after pressing CTRL_C in flnx demo program editor, I can not get keypress event any more from the nano-X server. I had to stop nano-X and restart it.
    Since I am not familiar with nano-X, I think my modification is incomplete and maybe there is some other better way. Your advice will be very important and useful to me.
    By the way, I am glad to commit my modification and wish it will do you good.
    The attachment is a winzip archive file.

Best regards!

MaTeng<tengma@redflag-linux.com>
P.R.China

["application/x-zip-compressed" not shown]

nanogui@linuxhacker.org