New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lmc_print_devices should give the text it prints (and some other stuff) . #19
Comments
ad 2: it's already there, just use
and you get e.g.
For the rest... stay tuned, the internal reset is already there when you relaunch the script so I can just link it to command. |
Thanks. While I wait for lmc_get_devices() to arrive, I will go on with the rest of the work. (I am happy already with the Luamacros http server, that I iniztially overlooked... I can get my Java thing to update its LUamacros counterpart directly when a user activates or deactivates [kind-of, waiting for the hard reset my thing just answer to LM "send the keys" instead of "I take charge"] ). Once the hard reset is there, I may also have M to reset when a new device is attached ( at which point, a window will pop-up to ask if it is a new things, or a migration of an old one to a new port... ) Thanks for your work |
Released, see forum post |
I have started working on a "java Client" to exploit LuaMacros ability to intercept keys ans use it to implement a general "programmable keyboards" controller, with various types of macros and with a comprehensive capability of generating application-dependent macro, manually selected use cases, title-dependent use cases and keeping track of various past versions of it.
I know, it is going to be a hell of work... I posted some of the code I did till now here
https://github.com/DaBotz/JavaMacros
Doing so, I come into a set of very small, but frustrating limitations of LuaMacros, problems in building and modding it on my computer (at first, I had issues with the Hilighter package, then with adding the INet package ) and I realized that it is time for me to update the "automatic GUI creator" class(es) that I use for everything.
(They are not nice, but they generate automatically controls from any object, and one has just to tweak their behaviour by implementing some limited business logic, which beats drawing controls around in WindowBuilder for me).
Business as usual
Anyway, I have found some issues with LuaMacros that I feel have a general relevance also to he rest of the world:
It would be nice that lmc_print_devices didn't just print the devices, but also gave back the text it prints. - _More ideally yet, if there was a lmc_list_devices that gave back an array (ehr, numbered map, if I understand well how Lua works) with the devices detected, people might do stuff with it. Us of now, I have stolen some code from https://github.com/mrsimb/macrorecorder and found my way around it, however functional it still makes for a bit of a mess at start-up, which leads to...
It would be good to have a "clear" function for the print window callable from Lua (to hide the aforementioned mess)
It would be a good thing to have a lmc_remove_handler function, to "detach" a device that is not in use for macros any more - alternatively, a "resetAllHandlers" would be good (I know... if I managed to have it built in my Lazarus, it would take some minutes to add it).
It would be wonderful if LuaMacros had a "hard reset" function, that allowed it to "completely restart", reset its table of system handles and re-load and re-launch the current script.
As of now, my Java "monstrosity" can detect when a new keyboard is plugged to the system, but I am forced to kill & re-launch LM (I hope those days had died with HidMacros) because it does not "see" it.
At first, I had tried to simply have the Lua script doing a "system re-scan", but then I realized that LM shares this old HidMacros limitation... it stores the device handles at start, and does not see "new ones", even when one knows that they must be there.
My thanks (and if I manage to get what I am doing wrong with Lazarus, I hope that I will be able to help) for both HidMacros and LuaMacros.
They really helped me (also, it amaze the people that see me drawing what one can do with them and a couple of 10$ numeric pads... ).
The text was updated successfully, but these errors were encountered: