Hello, I'm using jME and I'm trying to find out how Nifty does things.
I already found this callback mechanism: InputSystem -> NiftyInputConsumer -> Nifty.Screen -> KeyInputHandler and "ScreenControllers will implement KeyInputHandler, Nifty has a collection of them based on their class names" (inside the class 'Nifty').
But I still don't know what to make of this.
Basically what I want to achieve is this:
- find the implementation of the textfields for keyboard input handling (what Nifty does when it gets all those fancy keyEvents)
- use this code to place cursor, add letters, delete letters etc.
- find the implementation of the clipboard (CTRL-C, CTRL-V)
- make my own ingame console with colored fonts under jME, without using Nifty
Can you point me to the right locations in the Nifty code or manual, and maybe tell me more about those mysterious 'ScreenControllers implementing KeyInputHandler' ?
Sorry, I'm still a noob and the Nifty codebase is huge...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Page 76-79 in the 1.3.2 manual explains the basic of keyboard event handling and especially page 77 explains the "ScreenController implementing KeyInputHandler" part in detail. Really. I'm not kidding. I'm serious. It's all explained there :-)
And you could actually use github for questions as well. It's kinda hard to keep track of Nifty questions in several different places. That's why there is the note on the top directing people to github :)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
And yes, I will use the github tracker next time, if you like. I thought that it was only for bugreports and not for general discussions like 'where do I find ...?', you know.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello, I'm using jME and I'm trying to find out how Nifty does things.
I already found this callback mechanism: InputSystem -> NiftyInputConsumer -> Nifty.Screen -> KeyInputHandler and "ScreenControllers will implement KeyInputHandler, Nifty has a collection of them based on their class names" (inside the class 'Nifty').
But I still don't know what to make of this.
Basically what I want to achieve is this:
- find the implementation of the textfields for keyboard input handling (what Nifty does when it gets all those fancy keyEvents)
- use this code to place cursor, add letters, delete letters etc.
- find the implementation of the clipboard (CTRL-C, CTRL-V)
- make my own ingame console with colored fonts under jME, without using Nifty
Can you point me to the right locations in the Nifty code or manual, and maybe tell me more about those mysterious 'ScreenControllers implementing KeyInputHandler' ?
Sorry, I'm still a noob and the Nifty codebase is huge...
Page 76-79 in the 1.3.2 manual explains the basic of keyboard event handling and especially page 77 explains the "ScreenController implementing KeyInputHandler" part in detail. Really. I'm not kidding. I'm serious. It's all explained there :-)
And you could actually use github for questions as well. It's kinda hard to keep track of Nifty questions in several different places. That's why there is the note on the top directing people to github :)
Okay thanks. I just missed some projects, because the description on this site led me to the wrong place:
http://nifty-gui.sourceforge.net/nifty/source-repository.html
The better SVN directory is this:
https://nifty-gui.svn.sourceforge.net/svnroot/nifty-gui
I was looking here:
https://nifty-gui.svn.sourceforge.net/svnroot/nifty-gui/nifty
And yes, I will use the github tracker next time, if you like. I thought that it was only for bugreports and not for general discussions like 'where do I find ...?', you know.
argh that old page is still up? O_O sorry about that!
There is no svn for nifty anymore! The only true source is on github: https://github.com/void256/nifty-gui
Where did you find a link to http://nifty-gui.sourceforge.net/nifty/source-repository.html ? :)
I've removed that page now! Thanks for the hint ;)