Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Sat Jun 24, 2017 5:24 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Detect key pressed on linux
PostPosted: Fri Aug 10, 2012 11:00 am 
Offline

Joined: Wed Jun 27, 2012 3:26 pm
Posts: 27
Location: argentina
hi everyone! i just want to know how to detect the pressed key on linux (ubuntu 12.04)
on windows i use key.asc to get the numeric code and it works perfectly. on linux i use either key or key.asc and seems like doesn't work
thanks!


Top
 Profile  
Reply with quote  
 Post subject: Re: Detect key pressed on linux
PostPosted: Tue Feb 26, 2013 2:56 pm 
Offline

Joined: Fri Sep 14, 2007 5:00 pm
Posts: 408
I run OpenSuSE Linux, here is a sample of code I use to detect which keys are pressed. This code resides in the KeyDown area of an EditField. Hope this helps.

If(Key = Chr(27)) Then ' This is the escape key
mthKeydwn("Escape","Button")

ElseIf(Key = Chr(9)) Then ' This is the TAB key...
mthKeydwn("Tab","")

ElseIf Key = Chr(13) Or Key = Chr(3) Then
mthCalc

End If


Top
 Profile  
Reply with quote  
 Post subject: Re: Detect key pressed on linux
PostPosted: Tue Feb 26, 2013 4:09 pm 
Offline

Joined: Fri Nov 16, 2012 8:10 pm
Posts: 34
example app for key numbers - make your linux build

http://www.axel-erfurt.de/apps/key_number.rbp

_________________
OSX 10.8.3
ListBox Example Project OSX
TextEditor Example Project OSX
Homepage


Top
 Profile  
Reply with quote  
 Post subject: Re: Detect key pressed on linux
PostPosted: Wed Feb 27, 2013 10:12 am 
Offline

Joined: Wed Jun 27, 2012 3:26 pm
Posts: 27
Location: argentina
Thanks a lot... regards


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group