> On Oct. 25, 2013, 7:58 p.m., Xuetian Weng wrote: > > Could you also post a preview for French ? It should have 4 symbol on one > > key, I'd like to how that looks. > > Seems you didn't parse the led information? (It's ok to leave it there) > > > > Some key name doesn't looks correct (F1 - F12), could you use X11keysym.h > > to get the key name in X11? Or use XKeysymToString in libX11 maybe. > > > > Some key string position can be improved, for example, the "Space" in > > second screenshot. > > shivam makkar wrote: > I have no idea how to extract key names using X11, andriy rysin has done > the work related to mapping (for which I am really grateful to him). > It would be great if I could get some documentation or examples related > to this. > > I've french the french keyboard layout, it even support more than 4 > levels (like in german neo2 layout) it creates a combobox to select which > levels you want to display apart from level 1&2. > > Xuetian Weng wrote: > as I stated before, XKeysymToString will do the trick, man it then you > can find how to use it. It accepts a X11 keysym and return the key sym name > in /usr/include/X11/keysymdef.h > > And convert X11 keysym to unicode, you might want take a look at > libxkbcommon implementation > http://cgit.freedesktop.org/xorg/lib/libxkbcommon/tree/src/keysym-utf.c > > If we don't want libxkbcommon as dependency here, I think you can copy > some of the code. > >
Copying code is never a good idea (unless it's 2 lines of code) - Albert ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: http://git.reviewboard.kde.org/r/113413/#review42377 ----------------------------------------------------------- On Oct. 26, 2013, 1:12 p.m., shivam makkar wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > http://git.reviewboard.kde.org/r/113413/ > ----------------------------------------------------------- > > (Updated Oct. 26, 2013, 1:12 p.m.) > > > Review request for KDE Runtime, kde-workspace and Andriy Rysin. > > > Repository: kde-workspace > > > Description > ------- > > Improved keyboard layout preview > added geometry feature, multi-level keys (>4) and parsed geometry file using > Boost c++ libraries and tool tip showing symbol names. > my GSoC-13 project ! > > > Diffs > ----- > > kcontrol/keyboard/preview/geometry_components.cpp 65c47f0 > kcontrol/keyboard/preview/kbpreviewframe.h 7cfefa5 > kcontrol/keyboard/preview/kbpreviewframe.cpp 903a4f0 > kcontrol/keyboard/preview/keyboardpainter.cpp a740d44 > > Diff: http://git.reviewboard.kde.org/r/113413/diff/ > > > Testing > ------- > > > File Attachments > ---------------- > > English layout on default geometry > > http://git.reviewboard.kde.org/media/uploaded/files/2013/10/25/48fead43-1cfc-4cce-9d37-0943b3e780cd__snapshot11.jpg > french layout default geometry > > http://git.reviewboard.kde.org/media/uploaded/files/2013/10/26/19226ef7-53fd-4a43-af48-94731eca2cb5__snapshot13.jpg > Fixed position of the key names > > http://git.reviewboard.kde.org/media/uploaded/files/2013/10/26/cc9cae25-2366-4978-98b0-d83b41eabc09__snapshot14.jpg > german neo 2 with level 1,2,5,6 instead of 1,2,3,4 > > http://git.reviewboard.kde.org/media/uploaded/files/2013/10/26/584a9877-4875-48ce-957e-51b1cc19b76e__snapshot15.jpg > > > Thanks, > > shivam makkar > >