Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 19 Sep 2014, 16:02
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Projects
Need on-screen keyboard with mouse functions
Moderators: Flash, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 7 of 9 [134 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, 8, 9 Next
Author Message
ETP


Joined: 19 Oct 2010
Posts: 538
Location: UK

PostPosted: Thu 18 Apr 2013, 05:18    Post subject: The Pup With No Name - Final ISO (tpwnn_final.iso)  

The above is now available on my server. After yet another change of heart, I have reverted to launching Xvkbd at startup but then immediately minimising it. The Xvkbd mode on Radar will raise it as and when required. (You do not need to ever launch it from Radar Config)

The ISO remains screen resolution agnostic but I have optimised the size and position of Xvkd and tweaked its fonts for better clarity. Files changed include the following:

XVkbd-common
XVkbd-uk
htop.rc (cosmetic change)
AbiWord.Profile (attempt to get around its nasty habit of launching too small)
Inter (A Magoo panel script)
Start_xvkbd

The change to “inter” allows it to just launch the defaultbrowser. This allows for the choice between location home page and Google voice search to be changed within Chromium rather than having to edit scripts. By default voice is set.

On a 1920 monitor xvkb will be left of centre but on a 1280 monitor it should be centred.


Final Launch Sequence on boot up.

Radar
Xvkbd
Xvkbd minimises
Magoo panel with focus and cursor over “Skype”
Cursor moves to “WWW” icon
Message displays on screen and 30 second countdown starts.
After 30 seconds Chromium launches or the app of your choice if the mouse has been moved over its icon prior to the 30 second timeout.
The Google voice search page is displayed and after a few second the microphone is automatically activated.
If nothing is said, after about 10 seconds a “cancel/try again” box appears.
The mouse remains static but the “try again” box is then given keyboard focus so that a “return” key command can be issued from Radar. (Subsequent retries will require mouse navigation to the “try again button” followed by the issue of a left click)

To summarise the “do nothing option” results in access to voice search with nothing to press. Launching say Skype or email requires 2 presses just to move the cursor over another Magoo panel icon as the mouse click will fire automatically after 30 seconds.

I should add that “do nothing” includes not moving the mouse!

Radar:

Sfr has posted some guidance on its use here:
http://www.murga-linux.com/puppy/viewtopic.php?p=698276#698276

Tips:
1. With Google search it is not necessary to navigate to the search box. Having clicked on focus, select the Xvkbd option again and let the cross hairs run down off the virtual keyboard then issue a left click. Select the Xvkbd option again and start inputting text.

2. On boot up if you do not want to launch anything, for example when setting up, move the cursor off the Magoo panel onto an empty desktop area and allow the 30 second timeout to expire. The mouse fires 5 seconds after the blue “do nothing” message vanishes. You will see the keyboard focus move to the third icon after a further 17 seconds and can then proceed to set up the global font size, fontwizard and large cursor.

3. PageUp & PageDown off the Radar custom menu can be used to browse images when that Magoo panel option is invoked.

Setup Procedure for Final:

1. Complete the normal "first-run" dialogues and create a 512meg ext4 savefile.

2. Upon re-booting navigate to the desktop menu and set the global font size to 96 (Access this setting via the PupControl icon and its desktop tab.)

3. If you are using an LCD display, launch Fontwizard from the JWM/desktop menu, tick all boxes & then click on apply.

4. From the desktop menu select the “whitelarge” cursor theme then restart X.

Where to obtain the ISO: (305.6 MB - tpwnn_final.iso)

The ISO and MD5 are to be found here:
www.mydrive.ch
Guest login name = maddog@puppy4
Password= maddog
final.jpg
 Description   
 Filesize   78.6 KB
 Viewed   1234 Time(s)

final.jpg

tpwnn-final.png
 Description   
 Filesize   58.99 KB
 Viewed   1255 Time(s)

tpwnn-final.png

Thunderbird.png
 Description   
 Filesize   40.87 KB
 Viewed   1266 Time(s)

Thunderbird.png


_________________
Regards ETP
Accessibility Pups: -- Magoo -- The Pup With No Name -- MouseCam -- Obedient

Last edited by ETP on Mon 22 Apr 2013, 08:58; edited 4 times in total
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Sat 20 Apr 2013, 00:03    Post subject: Is there an easier way to achieve focus?  

Hi All,

@ETP -- Beautiful job of customization. Really love how clear and distinct you've gotten everything to appear, especially the symbols on the onscreen keyboard. I've been casing tpwnn looking for stuff I can appropriate for use on a wary 5.5 build. Mind passing on how you tweaked the fonts?

Currently my xvkbd startup script argument on a 1600x900 display is, code:

#!/bin/sh
read MAXX MAXY <<< `xwininfo -root | awk 'NR>=8&&NR<=9 {print $2}'`
xvkbd -geometry $(($MAXX*5315/10000))x$(($MAXY/5))+$(($MAXY*13/20))+$(($MAXX*10/24)) -always-on-top &

where it places the keyboard just above jwm's taskbar and to the right of radar's display. I haven't tried it yet on my Thinkpad T42 where my resolution would be 1024x768. The forumula isn't particularly elegant, and I'm not sure why it works as getting it involved a lot of trial and error. When I couldn't get my mind around bc, I figured the integer math of BASH would suffice: ignoring remainders as not being particularly important. The first two parameters (Width and Height) produced the right size, but the offsets from the keyboard's default top-left position weren't and what I thought were logical corrections to mistaken logic resulted in chaos. Hopefully, SFR, or someone, will put forward a elegant & universal formula for placing a keyboard of slightly more than one-half the screen-width and 20% of the screen height adjacent to radar if the later occupies the right-bottom corner +/-. Keeping the two close together is less visually distracting.
I think I've said it before, but radar's xvkbd mode does a really great job of making typing much easier. Hopefully, however, I've missed something running under wary, or something I don't recall overcoming under tpwnn. In order to type into Abiword, I have to:
(1) Open Abiword=several mouse-movements
(2) Click xvkbd's focus button=several mouse-movements or clicks to get into SVKBB mode;
(3) If in XVKBD Mode, allow the mouse to scroll off the keyboard and, in any event
(4) click move
(5) maneuver the cursor onto the text portion of Abiword's window; [Hint: allowing the cursor to scroll off the screen can be a short-cut)
(5) Click to stop further movement;
(6) Left-click to set focus on Abiword;
(7) click "more";
(Cool click XVKBD mode
(9) Begining to type and NEVER LET THE MOUSE SCROLL off the keyboard.
The above sequence has to be repeated to change focus from Abiword to a different receiver of text and, of course, repeated if I want to shift focus back to Abiword.
The point, however, is setting up can take a great deal of time and effort.
Some of the above can be eliminated if using something like xbindkeys can bind the opening (and maybe focus) of frequently used applications to xvkbd's function keys or Alt/Ctl/Meta + Keys. I'll be looking into that over the next couple of days. I don't want commands which will conflict with those built into commonly used applications, and in case of a conflict will see if the latter can be modified. Additionally, keyboard commands should be relatively easy to remember.
I wasn't able to use radar's Cycle mode to get xvkbd's typing focus on an application. Did I miss something?

mikesLr
Back to top
View user's profile Send private message 
SFR


Joined: 26 Oct 2011
Posts: 1068

PostPosted: Sat 20 Apr 2013, 10:18    Post subject:  

Quote:
xvkbd -geometry $(($MAXX*5315/10000))x$(($MAXY/5)) $(($MAXY*13/20)) $(($MAXX*10/24)) -always-on-top &

It works fine with my 1366x768.
However, since you asked, here's a variation, which works almost the same, but makes it easier to customize offsets from right and bottom screen edges (here: 192px & 64px respectively):
Code:
xvkbd -geometry $(($MAXX/2))x$(($MAXY/5))+$((($MAXX/2)-192))+$(($MAXY-($MAXY/5)-64)) -always-on-top

To add that "slightly more than one-half the screen-width", eg:
Code:
xvkbd -geometry $((($MAXX/2)+($MAXX/8)))x$(($MAXY/5))+$((($MAXX/2)-($MAXX/8)-192))+$(($MAXY-($MAXY/5)-64)) -always-on-top

which is ½+⅛=⅝ of screen-width.
I tried this only with 1366x768, but I think should be ok also in other res.

Quote:
I wasn't able to use radar's Cycle mode to get xvkbd's typing focus on an application. Did I miss something?

It seems to depend on WM.
So far "only" under Compiz, Fluxbox, Openbox, XFCE and LXDE it works this way, but no go under JWM/IceWM - 'Focus' button must be used every time there...
The culprit is that when entering XVKBD-mode, xvkbd window is being activated/focused, therefore xvkbd sends keystrokes to itself.
But Compiz/Fluxbox/Openbox/XFCE/LXDE, somehow, don't focus the xvkbd window completely (only bring it to top), leaving the "real" focus on a window that was on-top before...

Another thought: since you're using 'xvkbd -always-on-top', commenting out or deleting the following line in 'radar-main' script:
"$XDOTOOL" windowactivate $XVKBD_WIN
might (I didn't test it) prevent such behavior under JWM/IceWM.

Greetings!

_________________
[O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource
Omnia mea mecum porto.
Back to top
View user's profile Send private message 
ETP


Joined: 19 Oct 2010
Posts: 538
Location: UK

PostPosted: Sun 21 Apr 2013, 08:56    Post subject: Xvkbd fonts plus more impending changes to TPWNN  

@mikeslr

Launching Xvkbd from a terminal will show if you have an issue with fonts.
I suspect that this will be base puppy dependant. In the case of precise there was an issue with lucidatypewriter and lucida.
The guidance can be found here:
http://homepage3.nifty.com/tsato/xvkbd/faq.html
Installing font packages as suggested, did not do the trick, so I simply changed everything to helvetica and also changed some styles and point sizes. I did not find a way of improving the fonts in the “words” window. The following is now contained in XVkbd-common with XVkbd-uk being changed to call it.

Code:
XVkbd*Font: -*-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*generalFont: -*-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*letterFont: -*-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*specialFont: -*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*keypadFont: -*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*banner.font: -*-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1
XVkbd*display_panel*label.font: -*-helvetica-bold-r-*-*-14-*-*-*-*-*-iso8859-1


I have made more changes to TPWNN in order to auto-launch the word completion window as it was very tricky to launch it manually and it is a vital requirement to cut down on switch presses.
After some more testing I will re-upload the “tpwnn_final.iso”.

_________________
Regards ETP
Accessibility Pups: -- Magoo -- The Pup With No Name -- MouseCam -- Obedient
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Sun 21 Apr 2013, 12:02    Post subject: Thanks, and further notes  

Hi All, SFR & ETP

Thanks SFR for the positioning formula. My fudge didn't work in my Thinkpad T42 1024x768 Graphics. Will try-out your formula sometime today. But especially thanks for the information regarding the limitation of xvkbd when run under jwm. Although I want to build a Pup based on Wary (so that it can be deployed to old/cheap-2nd-hand laptops) more important is a system which doesn't get in its own way. So I considered alternative base-pups. However, wondering whether Wary could be run with an alternative window-manager lead me to Tote's post that vicmz's Openbox+Extra, http://www.murga-linux.com/puppy/viewtopic.php?t=82800, worked (at least if the lxpanel rather than the Tint2 panel choice was made http://www.murga-linux.com/puppy/viewtopic.php?p=689125#689125). I'll try that approach first. Caveat: I, at least, couldn't find anyway under this Openbox to select ETP's great finds of LargeWhite Cursor, faenza_lrxw icon theme or UbuntuFont. They could be installed, just not selected. But if selected while running jwm, they carried over when the switch to OpenBox was made. I'll have to see whether this Openbox under Wary presents any obstacles to the essential applications: xvkbd and SFR's radar.
Thanks ETP for the information about fonts. I saw that discussion on xvkbd's faq. But my ignorance in the area of font use/customization turned it into gibberish.
On thing I stumbled across while experimenting with positioning may help if you aren't able to achieve a formula solution. It seems to be one of Puppy's hidden talents, or at least one I was here-to-fore unaware of. I had sized and positioned xvkbd's onscreen keyboard. Right-clicking the top edge produced a drop-down menu, one of whose choices was “stick.” By that time I was frustrated enough to want to use one. Having nothing to loose I figured I'd take a wake at it. So I clicked it. Which immediately did nothing. However, on closing and re-opening it displayed it at its former location, over-riding the positioning formula. And that position and size was retained after both restarting X and rebooting. It, however, won't survive manual resizing or repositioning. The stick option also worked with Abiword and a couple other applications I tried.
Now that you've explored xvkbd's faq and documentation, you may have reached the same suspicion I have that re-mapping the keyboard may be as simple (though time-consuming) as re-structuring the arrays set out in the keyboard files. Trying that is actually on my ToDo List. I've put it off until three other aspects were solved: (1) getting radar's XVKBD mode to function as it should will indicate which should be closest to its “starting point” on the keyboard when that mode is activated; and (2) determining which hot-keys and (3) special key combinations would be most useful.
Although remapping seems “simple” --doesn't everything before you try to do it?-- I've run across a couple of posts which indicate reconfiguring –that is, adding or eliminating keys-- presented problems. I've also run across posts indicating problems with xvkbd's module which is supposed to handle events: so “fancy” stuff may have to be achieved by system-wide keybindings.
Did I mention that in Abiword, you can select a word or phrase by pressing Shift-and-one of the direction keys; once selected it can be copied to the clipboard (Ctrl-c) and then pasted (Ctrl-v) into a leafpad file such as “Words” being used by xvkbd?
Project for another day: About a dozen years ago, using GIMP's toolkit, David Allen created GTKeyboard. http://www.gnu.org/software/gtkeyboard/. Muggins created a pet. http://www.murga-linux.com/puppy/viewtopic.php?search_id=1515044431&t=21634. Unfortunately, Allen no longer maintains it, and the glibs used conflict with modern Pups. It was last available under Ubuntu Hardy. And, at least, one lib is no longer available anywhere. Were it still functional, it would have advantage over xvkbd in that it was more customizable, including having a top row to which could used as launchers for other applications.

mikesLr

Last edited by mikeslr on Sun 21 Apr 2013, 14:44; edited 1 time in total
Back to top
View user's profile Send private message 
ETP


Joined: 19 Oct 2010
Posts: 538
Location: UK

PostPosted: Sun 21 Apr 2013, 13:56    Post subject: Changes to TPWNN  

Hi All,
I have now re-uploaded TPWNN with its auto-launch of the "Word completion" window. When xvkb is selected on Radar both windows will be raised.
The positioning should suit a wide range of resolutions.
image-1.png
Description 
png

 Download 
Filename  image-1.png 
Filesize  116.08 KB 
Downloaded  399 Time(s) 

_________________
Regards ETP
Accessibility Pups: -- Magoo -- The Pup With No Name -- MouseCam -- Obedient
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Fri 03 May 2013, 14:45    Post subject: Alternate "words" file for xvkbd  

Hi All,

I've been busy exploring possibilities but, as yet, don't have anything worth publishing except an alternate "words" file to be used with xvkbd's word-completion module.
In the single switch frame of reference, the words file poses a Goldilock's problem: too few words and it requires more typing and more adding to the list; too many and it takes too much time to make a selection. I've forgotten the exact number, but I think that Ubuntu's "small" list had about 50,000 entries. So I wondered if somewhere on the web there might be a list of about 5,000 of the most frequently used words.
One thing great about the internet is that somewhere someone --having an odd view of what is important-- has, by now, posted what the rest of us might consider trivia. I can appreciate that "important" is a relative term. For eight years I was addicted to Bridge.
Sure enough some Scrabble fans thought to post a list of 10,000 most frequently used words in the English Language --well at least among scrabble players-- arranged in order of frequency. Considering that words of less 4 letters would be more trouble than they're worth, I copied the first 6.000 into a file and the used Bash's sort command to alphabetize it. [Wasn't sure if Sato had built sorting into xvkbd]. Then deleted all words having less than 4 letters. Also discovered that some Scrabble players may have cheated in preparing the list as some words on it were obviously French or German, and there were many "near" duplicates in that a word would appear two or three times, once with all small letters, once with a beginning capital, and once with all capitals. At any rate, unless the word was obviously a name, I deleted duplicates. I left in "near-duplicates" where the distinguishing character was an ending "s" denoting a plural.
Not exactly a scientifically developed list, but probably "close enough for government work."
Attached is a "words" file. It can be used by removing the false ".zip" from the file and placing it in the /usr/share/dict folder.

mikesLr
words.zip
Description  remove false ".zip" including the dot, and place in /usr/share/dict
zip

 Download 
Filename  words.zip 
Filesize  33.21 KB 
Downloaded  369 Time(s) 
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Sun 05 May 2013, 20:22    Post subject: Selecting text: xvkbd + radar in xvkbd mode  

Hi All,

Stumbled on this while reading xvkbd's site for something else. Each of what it refers to as Quick Modifiers can be set to "locked" in xvkbd's property panel: Right-click xvkbd "label" on bottom left of keyboard. Once "Shift" is "locked" the usual editing commands --shift+arrows-- can be used while in radars xvkbd mode to select text (more than one key at a time) for copying to the clipboard via Ctl+c or Ctl+x and subsequent pasting via Ctl+v. Caution: I'm Just starting to experiment. I don't know what functions locking "shift" may interfere with. Please post if you find any. Locking survives a reboot. Getting out of "selection mode" may require that the Esc key be pressed.

mikesLr
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Fri 17 May 2013, 22:57    Post subject: Letter Frequency Keyboard for xvkbd & radar/navbar  

Hi All,
Caution: requires an upgrade of radar/Navbar. See SFR's post below for the link.

Attached you'll find a modified keyboard for use with xvkbd. The attached picture shows what it will look like when installed. According to the xvkbd website there are four ways to set alternative keyboard as the default. But the only way I found –and understood-- was as follows: There's a file named “xvkbd” in /etc/X11/app-defaults. Rename it “xvkbd-original” --in case something gets screwed up. Download the attached to somewhere and delete the false zip ending. Copy it to /etc/x11/app-defaults, and then delete the “-1switch” suffix. Restart xvkbd. I'd be interested if anyone figures out how to use any of the other three methods and is willing to re-phrase them into instructions a noob could follow.
Early on I had two recommendations for the One-Switch environment: (1) the use of keyboard shortcuts whenever possible rather than directing the mouse-cursor and clicking; (2) re-arranging the keys so that the most frequently used keys would be at the beginning of the automatic scrolling path taken. Recent developments by SFR to radar (and I assume Navbar) have gone a long way toward accomplishing the first. Hopefully, this modified keyboard will bring the second objective as close. The second would not have been possible were it not for the tremendous job SFR did in developing radar/Navbar.
If you're a touch typist, the keyboard makes little sense. It was designed to take advantage of the automatic scrolling routine of radar running in xvkbd mode. In that mode, unless the Shift, Ctrl, Alt, or Meta keys are “locked” through xvkbd's property menu and pressed, after a keypress of other than the foregoing keys is effected (by pressing the button while the mouse-cursor is over a keyboard symbol) the symbol selected is sent to the target application and the mouse-cursor is returned to the top left corner of the keyboard where it automatically begins to scroll down until the button is again pressed. Following that press, the mouse-cursor scrolls right until the button is again pressed sending the symbol to the target application and starting the mouse-cursor, again, in its scrolling pattern.
With that scrolling pattern in mind, it makes sense to arrange to keyboard so that the most frequently used keys will be closest to the top-left of the keyboard. While it may be possible to place Function Keys other than on the top row (and so use the top row for other symbols) Tom Sato, in designing Xvkbd, enabled the keyboard to be loaded without the Function Key Row. I claim absolutely no knowledge of how xvkbd was constructed or its internal structure. So I decided not to mess with the Function Key Row too much. You'll notice, however, that I've made three changes to the top row of keys. I substituted the space bar for the customary Backspace bar, and moved it to the first, rather than last, position in that row. And I added an Esc key.
I don't know of any scientific studies, but in testing the speed of typists, regardless of how many words may actually appear on the sample to be duplicated, 20 printed symbols are counted as 4 words. Which, in practical terms, suggests that a space between actually words will take place roughly after every five other characters or, in other words, make up 16.67% of key-presses. According to the analysis of letter frequency which came out of the Gutenberg Project –which only considered alphabetic symbols-- only the letter “e” would be pressed more frequently. The Esc (short for Escape) key on the top row, and those on each other row serves a particular purpose. While each Escape key serves as an Escape key within any target program, I believe they provide an important function to radar operating in xvkbd mode: they are non-printing characters which, when pressed, return the mouse-cursor to its "start" position.
Murphy's Law obtains and will, I suspect, be especially evident to a user until the key arrangement becomes second nature. Without an Escape key, if the button is pressed sending the mouse-cursor to the right on the wrong row only two options exist: (1) allow the mouse-cursor to scroll beyond the keyboard taking radar out of its xvkbd mode, or intentionally pressing the wrong key. Both of those would be time consuming, and having to delete (backspace over) unwanted characters really annoying.
The first 7 letters starting from the left on the second row are 7 of the eight letters which, according to the Gutenberg Project Analysis, make up 66% of letter usage. “H” is the eight of those letters, and the first letter on the next row. It is followed by 3 of the 4 next most frequently employed letters. Those 12 characters make up roughly 80% of letters appearing in English text. The 4th, “U” is preceded by the “.” which “Gutenberg” didn't factor into its analysis, but which I suspect shows up more frequently that “u/U”. The remaining letters of the English Alphabetic were similarly placed: their respective distances from “the starting point” proportionate to the infrequency of their use.
Having thus mangled the Alphabet, I decided little would be gained by disordering the natural sequence of numbers. Indeed, having the number 0 thru 4, which can suffice for entire words in informal writing, the – (which can be used as a dash) and its obverse, +, in a fairly convenient locations seemed to make some sense.
Similarly, so did having the direction keys –used to make menu selections, and to effect cut/copy/paste operations.
The symbols appearing in the Shift position above numbers were similarly re-arranged based on my guess as to which would be most often used.
While it is possible to move mode keys (such as Ctrl, Alt and Meta) and non-printing keys such as Enter, Tab and Delete from their “common” positions on the right and left edges and bottom row, doing so makes it far more complex to arrange the keys in orderly rows. Of course, my efforts to do so took place before I figured out three “magic” numbers Tom Sato employed in structuring the “common” keyboard. The first number is the sum of the width of all keys on a row must add up to 450. Ordinary keys (those used for Alphanumerics) have a width of 30. The “xvkbd” appearing at the bottom left, but referred to in the data file in structuring the keyboard as MainMenu, is at least 28, but is best determined by subtracting the width of all other bottom row keys from 450. If the number you get is too big, adjust the width of the other keys.
Using 450, the keyboard appears as show when opened without geometry arguments. The arguments currently in use will have to be adjusted slightly as the right edge comes too soon, cutting off some part of the intended display of the right-most keys.
What didn't work: Having six Esc keys didn't leave sufficient room to include all the non-alphanumeric symbols found on the “common” keyboard. I had to leave out two. To include them, I would have had to reduce the 30 used for alphanumerics. Frankly, I don't know what command Tom Sato used to give them a width of 30. Eliminating two symbols, I would have preferred to leave out the “^” and the “|”, including instead “`” and “\” or perhaps the “£”. It should be possible to include any of those three. The “\” however is tricky. It is the Escape symbol and so can be read by the program creating the keyboard display to “Escape” and, therefore, ignore the instructions which follow it. I know it's possible to include it not only because it appears on the common keyboard, but also because I was able to include it in an early version. But in that version all I did was leave it, and its Shifted companion, where they appeared on the common keyboard. I didn't try to move it, or place it in the Shifted position. Once I moved it, it caused havoc to the keys which followed it. “`” displayed, but wouldn't print. “£” displayed with a preceding sort of “A” and wouldn't print. So I suggest to anyone –Hi ETP-- if you want the “£” sign, leave both it and its non-shifted companion together.
What sometimes didn't work: Let me first say what did. Many applications have built in keyboard shortcuts employing the Ctrl and the Function Keys. These worked. But at least in learning an application, even if later on Ctrl-something may be more expeditious, the ability to access a program's menu by pressing Alt-f for files, or Alt-e for edit, and such, and then using the direction keys would be of substantial value. Unfortunately, while some applications responded to Alt-something, others did not. And that failure wasn't the result of my re-ordering the keys. The same applications wouldn't work when xvkbd's default keyboard was used. Unfortunately, among the applications which didn't work were Abiword, Geany and Leafpad. What would happen is that, for example if Alt-f were pressed, the Files section of the menu would indicate that it had been selected, but the Menu would not drop down. Pressing the down down direction key, or the Enter key did noting. Except to move back and forth on an non-functioning Menu using the direction keys, no further action could be taken until an Esc key was pressed. My work-around to this problem included using Xfe's built-in text editor (rather than geany or leafpad) and loading OpenOffice Lite. LibreOffice will probably also work. As may some other version of Abiword. Or perhaps the difficulty is wary (5.5?) specific. OpenOffice Lite provides full-fledged wordprocessor, spreadsheet and presentation program, albeit its has far fewer keyboard commands than Abiword. And I haven't tried to set Xfe's built in text editor, xfw, as the default text editor.

mikesLr
Keys_by_Frequency.png
 Description   Screenshot of modified xvkbd keyboard
 Filesize   10.66 KB
 Viewed   967 Time(s)

Keys_by_Frequency.png

XVkbd-1switch.zip
Description  Keyboard arranged by letter frequency. Note delete false dot-zip ending
zip

 Download 
Filename  XVkbd-1switch.zip 
Filesize  2.36 KB 
Downloaded  348 Time(s) 

Last edited by mikeslr on Tue 21 May 2013, 10:37; edited 1 time in total
Back to top
View user's profile Send private message 
SFR


Joined: 26 Oct 2011
Posts: 1068

PostPosted: Sat 18 May 2013, 09:59    Post subject:  

mikeslr wrote:
Not sure why radar is closing when xvkbd mode is selected.

Hi Mike

It's because I was using xwininfo to read dimensions of XVKBD window by its name: "xvkbd - Virtual Keyboard" and xwininfo couldn't find it due to additional "(One Switch)" string:
xvkbd.title: xvkbd - Virtual Keyboard (OneSwitch)

But it's been fixed in v1.1.2, so now it works ok.

However, in order to be able to find XVKBD window at all I need it to have a certain, concrete string in its name, so let's say that the initial sequence of window name must be always:
xvkbd - Virtual Keyboard
and after it you can freely add other characters, ok? Wink

Btw, nice job with the keymap!

Greetings!

_________________
[O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource
Omnia mea mecum porto.
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Mon 20 May 2013, 01:21    Post subject: Alternate Keyboard Exploration  

Hi SFR,

I kind of guessed it might be the way radar/Navbar located the corner of xvkbd's onscreen keyboard, but as much of their code is above my level of understanding I wasn't going to ask before checking out other possibilities. For a modified keyboard to work all the following must be properly functioning together: the computer's hardware, the operating system (in this case a version of Puppy), xvkbd, radar or navbar and the modification.
Going back to the drawing board was not without its benefits. I had been using wary 5.5. But since wary might have been the problem I decided to build a pup using Precise. While it didn't solve the "radar closing" problem, it made it clear that xvkbd's inability to open menus using Alt-KeyLetter combinations was a wary failing. Precise functions properly.
Another possibility was that my modifications were too radical: that "non-printing" control keys, such as Ctrl, space, Backspace, and so on were limited to the edges by xvkbd. So I re-designed a keyboard which only re-arranged the "printing" characters. Although it might in the hands of an experienced user add a little to the time it takes to accomplish something, it was in many ways more rational and would be easier to learn. Now that the "radar closing problem" is solved, I'll rework it as an alternative to the keyboard I posted.

Thanks again for your continuing efforts on this project. I do hope you've enjoyed the challenge and aren't getting bored with it. I'll email you about a couple other ideas I've had. But it seems to have gotten to be about 1:27 in the morning. So I'll leave that to another day.

mikesLr

Last edited by mikeslr on Tue 21 May 2013, 10:43; edited 2 times in total
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Mon 20 May 2013, 02:14    Post subject: Question for anyone interested in this project  

Hi All,

I've used Wary 5.5 and Upup 3.72 to explore xvkbd and radar/navbar. When xvkbd is started from a terminal a message appears about the possibility that the AltGr key may not work. But I've only used, and modified, the "common=US default" and the UK keyboard which don't include an AltGr key. Being in the US, and limited in my language ability to English, I'll leave resolution of any problems with AltGr to others. My concern is keys that apparently have been included in all of Tom Sato's builds, but don't seem to function on either of the two computers I've worked with: a ZT system built around a 4x AMD Phenom(tm) II X4 945 Processor, and an IBM Thinkpad T42.
The first of those keys bears the label "Meta." I've read that its supposed to function as the "Windows" key on the US International Keyboard, or (I think) the Super_L key on a Mac. (Not having a Mac, I wasn't paying much attention). But on my computers it not only does nothing, running XEV and clicking it --or it and another key-- fails to indicate anything beyond that the other key was pressed. The Meta key could be used to create keyboard commands that didn't conflict with keyboard commands built into the windows manager or applications. But if pressing it doesn't register as a recognizable event, than Meta keys are just occupying space which could be better used for keys which are recognizable. Does anyone have a system which recognizes the Meta Keys? And if so, does anyone know how to make use of them?
The other key which, at least on my systems, appears to just occupy space is the "Compose" Key. In the file which creates the keyboard layout although it bears the label "compose", it is otherwise referred to as the Multi_Key. Does anyone know what its supposed to do, and how to use it?
Another almost superfluous key is CapLocks. With xvkbd's properties set to lock the shift key, and Shift clicked on the clicking of all further keys will generated their shifted symbols. The only reason to use Caplocks instead would be to type Capital Letters together with numbers. Shift, while on, will print the symbols over the numbers rather than the numbers.
As I previously mentioned, in order to include an "Esc=Escape" key on each row, I've had to leave out some little used symbols found on the "Common" keyboard. There are at least two symbols found on the UK keyboard that also could be included. I'm sure that I can find other symbols that would have some use. So I'd like some feedback and suggestions.

mikesLr

Last edited by mikeslr on Tue 21 May 2013, 11:04; edited 1 time in total
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Tue 21 May 2013, 10:54    Post subject: Alternate Letter Frequency Keyboard for xvkbd & radar/navbar  

Hi All,

I've attached an alternate keyboard for use with xvkbd and radar or Navbar. Also attached is a photo of how it will appear. See my last couple of posts for explanations of the advantage and disadvantage of this arrangement of keys, and instructions of how to put it to use.

Happy Computing,

mikesLr


P.S. According to the analysis of letter frequency based on the Gutenberg Project
E T A O I N S H R D L U
are the 12 most frequently used letters. You may wonder why they weren't all placed on the first row below the Function Keys. When radar/Navbar goes into xvkbd mode it begins to scroll down the left edge of the onscreen keyboard until the "button" is pressed, at which time it begins to scroll to the right. I "guestimated" that the letters HRDLU, despite their being on the "2nd" row, would be reached faster than if they were at the right end of the "1st" row. And see my previous posts regarding the reason for including the "." among the earliest symbols to be reached.
XVkbd-1switchB.zip
Description  Delete false Zip, and version designation "-1switchB"
zip

 Download 
Filename  XVkbd-1switchB.zip 
Filesize  2.74 KB 
Downloaded  326 Time(s) 
XVkbd-1switchB.png
 Description   View of keyboard B.
 Filesize   14.52 KB
 Viewed   829 Time(s)

XVkbd-1switchB.png

Back to top
View user's profile Send private message 
ETP


Joined: 19 Oct 2010
Posts: 538
Location: UK

PostPosted: Tue 21 May 2013, 15:48    Post subject: Alternate Letter Frequency Keyboard for xvkbd & radar/navbar  

Hi mikeslr,
That looks fine. I would not worry about AltGr as the French will be using their own k/b layout and we Brits make little use of the euro symbol € Laughing
I have found that the meta keys do not work with jwm but IIRC Tom did warn that not all features of Xvkbd would work with some WMs.
My only suggestion is (If possible) you might like to swap the positions of the Focus and Meta keys on the bottom line as it is a pain
waiting for the cursor to traverse to what will probabably be a frequently used key.
ps
I sent you a PM on the 28th April which you do not appear to have accessed.

_________________
Regards ETP
Accessibility Pups: -- Magoo -- The Pup With No Name -- MouseCam -- Obedient
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 781
Location: Union New Jersey USA

PostPosted: Wed 22 May 2013, 13:26    Post subject: Regarding modification of the xvkbd keyboard  

Hi ETP,

I was going to swap the Focus and Meta Key per your request, and will be happy to if you still want that. But subscribing to the philosophy “Give a man a fish and you feed him one day. Teach a man to fish and you feed him for a life time” I think it would be better if I clearly explained how to modify the keyboard: something others, not merely those using Puppy, googling for advice, may have difficulty finding. It's not really difficult: mostly tediously keeping track of things during a major re-arrangement. Rather annoying to be sitting back admiring the aesthetics and probable functionality of your arrangement and realize you haven't included the letter “B.”
And, at any rate, your modification of the fonts –by proving that what Tom Sato referred to as resources-- were merely text which could be modified without bringing on Gotterdammerung encouraged me to make the effort.
All the keyboard files Sato provided –including the one which appears with the icon “C” and those which appear with “ShipWheel=applications” icons are configuration files which can be opened in a text editor. As per Tom Sato's instructions, if you modify the keyboard, the first command you have to provide is:
#include "XVkbd-common"
I'm not sure why it begins with the # sign.
Basically than what your modifications do is make substitutions (overwrite) the default commands set out in the Xvkbd-common.
There's a section in Xvkbd-common which reads:

XVkbd*Command.height: 30
XVkbd*Repeater.height: 30
XVkbd*banner.height: 30
XVkbd*row0.Repeater.height: 25
XVkbd*Command.width: 30
XVkbd*Repeater.width: 30
XVkbd*space.width: 80
XVkbd*Tab.width: 45
XVkbd*Control_L.width: 60
XVkbd*Shift_L.width: 75
XVkbd*Shift_R.width: 40
XVkbd*Multi_key.width: 35
XVkbd*Caps_Lock.width: 35
XVkbd*Alt_L.width: 38
XVkbd*Alt_R.width: 38
XVkbd*Meta_L.width: 38
XVkbd*Meta_R.width: 38
XVkbd*BackSpace.width: 75
XVkbd*Delete.width: 45
XVkbd*Return.width: 60
XVkbd*row5.Focus.width: 35
xvkbd*Mode_switch.width: 45

The foregoing provides the default “size” of the keys. According to Sato, if you want to eliminate a key entirely, you give it a length of 1. I think the numbers are NOT linked to some common unit of measurement, but rather to some relative length which the xvkbd application creates, thus enabling the keyboard to be resized. You had mentioned your use of the UK keyboard, and my examination of it revealed that in it Sato had modified the default XVkbd*Shift_L.width: 75 to xvkbd*Shift_L.width: 45. (Just noticed: these commands don't seem to be not case sensitive).
Comparison of the UK keyboard's “resources/sections” having to do with Keys (=what symbol are sent to a target application) and KeyLabels (=what symbols would appear on the keyboard) suggested that the key “Multi_key” bore the label “Compose” and “MainMenu” bore the label “xvkbd”. As the above list made no reference to “normal key width” I guessed that Sato's term “repeater.width” had that meaning. Intuitively, I guessed that the keyboard length (exclusive of the keypad) was about 450. I first tried 452 (don't remember why) but it cut off the right edge. Later I realized that on the UK keyboard's “Shift Key Row”, if you add up the lengths of the Shift_L, Shift_R, Multi_key and 11 “repeater” keys with a width of 30, you get 450. So 450 is the “magic” row width, and 30 is --unless otherwise specified--the default key width . After that, everything else pretty much falls into place. (Undertaking a radical re-arrangement, I used a spreadsheet to keep track of resultant row widths, and where reduction/extension of a key-width was necessary included in the alternate keyboard file being created an appropriate width-command). Note, however, that the directional keys (arrows) start with a capital letter in the Key Sections, and a small letter in the KeyLabel sections. (Not sure if that's required).
Regarding just swapping the Focus and Meta keys, as both are on the same row and so don't require modifying the lengths of rows, it's an easy “cut-and-paste” in five resources/sections:
Open the keyboard in a text editor and scroll down to the section which starts with, “xvkbd.NormalKeys: \” and note that the last line of this section reads:
MainMenu Alt_L Down Right Up Left Meta_L space Escape Caps_Lock Multi_key Focus
Just cut Focus from the end and paste it in front of Meta_L; then cut Meta_L and past it on the end. Make sure you leave spaces between “words.”
As the “xvkbd.ShiftKeys: \” section produces the same key presses as the “xvkbd.NormalKeys: \”, you can modify the last row by now merely cutting and pasting (over-writing) its last row with your new last row from the “xvkbd.NormalKeys: \” section.
Perform a similar operation to the “xvkbd.KeyLabels: \” section, noting that the reason you can't just over-write the last row with the text in the clipboard is that in the Labels Sections the “text” of the Labels are not the same as the “text” of the Key (commands) section. But since the text of the last rows in each of the Labels sections are identical, once you've modified one, you can copy/paste (over-write) it to the other two.
For those desiring to modify those keys where the key-sent-to-target-application and the symbol appearing on the keyboard will depend on whether or not the Shift (or AltGr?) key has been pressed, the key text of the "xvkbd.KeyLabels: \" section --and only that section-- takes the form A\nB: that is top(shifted)-symbol backslash n bottom-(unshifted) symbol. The "n" is NOT a command to use numbers, but rather to generate a New Line within the key label. As I mentioned elsewhere, creating a key for \ --the backslash-- is difficult as xvkbd may read the \ as "Escape" ignoring everything which follows.
Before making the above changes, however, if the Focus key is going to be used fairly often, you may want to place it before the direction keys. Or you may want to try a window manager other than jwm. According to SFR, the need to Focus on a target application has to do with jwm (and icewm) not being fully xdg compatible.
Actually, I wasn't so much concerned about non-functioning AltGr keys as my inability to include a functioning British pound key. I know money itself doesn't concern you, but others in the Kingdom may be more materialistic.
Final thought, perhaps for the AltGr key to function, one of shinobar's multilingual language packs must be pre-installled.


mikesLr
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 7 of 9 [134 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, 8, 9 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Puppy Projects
Jump to:  

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
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1945s ][ Queries: 13 (0.0083s) ][ GZIP on ]