Announcement

Collapse
No announcement yet.

Phone style text input applet (with Source code!)

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Phone style text input applet (with Source code!)

    Hi guys,

    for all of those not fortunate enough to have touch screens, i have written this little app to allow text input using a numpad the same way you would enter text on an SMS.

    I tried out the Girder 'Nokia Style Input' layout, but it wasnt very usable!, so here is my offering. You need to use Girder, and in there you assign one of the Numpad keys to launch my applet ('/' or '*', or if you have any extra keys around the numpad they would be cool). Then Assign another key to perform a Paste operation (Ctrl+V)

    Now, it all works like this: In your Media/GPS app you come across a field that requires text input. When the cursor is on the field press the key you assigned to launch my applet. The input window pops up and you can enter the text just as you would on a phone:
    Note that the numpad keys are mapped out as follows:
    1 2 3
    4 5 6
    7 8 9
    0
    (to match the phone keypad)

    1=punctuation
    2=abc
    3=def.. etc
    0=Space
    . (del) = Shift or Caps (once for single letter shift, twice for caps lock, again to cancel)
    + Cancels the timer (i.e. 'Accept this letter now') - useful for fast typing!
    - deletes last char

    When you are done typing your word, you hit 'Enter'. This will copy the current text to the clipboard, and close my applet.

    Now you should be back in your original app, with the cursor still on the field you want to fill in. Just press the key you assigned to Paste, and Bingo, you have filled out your field!!!


    Note that this is just a quick attempt, i am open to suggestions (one thing i plan to do is for it to read a text file to determine the key mappings instead of being hardcoded - so that you can add different mappings/characters for your language.

    Developers please feel free to use/modify/do whatever with the source which i have included in the Zip file - perhaps you could embed it into your application! If it is useful to you, i wouldnt mind being credited somewhere in your app; but if you dont then its ok...
    Attached Files

  • #2
    Sounds good - now you just gotta code the T9 predictive text input...
    In da club....

    ALIZEE WANTS YOU.....

    (\__/)
    (='.'=)
    (")_(")
    Bunny's first poo
    __ U

    Comment


    • #3
      Dominik,

      It looks good It was something I was planning on implementing within AIMEE, so if it is OK with you, I will take a look at your code, and use it as a basis for this section in AIMEE


      Regards,

      Garry
      Co-Developer of A.I.M.E.E
      www.aimee.cc

      Comment


      • #4
        Confused, i actually saw your post in a previous thread, which is what got me started.

        The code would be easy to adapt to any VB text field, you just need to have a flag which would lock the field (to stop the numbers coming up on the field!!), and process the Keypress Event.

        T9 is coming. Speed will be a huge issue with that; The dictionary file i have has about 188,000 words, and even if its indexed it will be a pig for long words...

        Comment


        • #5
          erm...I was just kiddin' about the T9!!!
          But if you can implement it...
          In da club....

          ALIZEE WANTS YOU.....

          (\__/)
          (='.'=)
          (")_(")
          Bunny's first poo
          __ U

          Comment


          • #6
            I have the program structure worked out (simple recursive function); Gimme about a week (I dont have VB at home, so the only time i can do it is while i dont have anything to do at work!)

            Comment


            • #7
              would be really cool if someone made an onscreen keyboard like this

              I didnt download yet and try out, but do you have to use girder for this to work? Cant it just detect any number keys as phone style text? Or made to do so? I have a RF remote and it would be cool to use that to type with, without the help of girder.

              Thanks
              01101100 01101001 01110001 01110101 01101001 01100100 01011111 01110011
              01101101 01101111 01101011 01100101

              beer replenishment fund
              http://www.mp3car.com/vbulletin/forumdisplay.php?f=93
              mp3car live search

              i have joost invites, just hit me up for one.

              Comment


              • #8
                Yeah would be pretty cool for phone control
                In da club....

                ALIZEE WANTS YOU.....

                (\__/)
                (='.'=)
                (")_(")
                Bunny's first poo
                __ U

                Comment


                • #9
                  I added onscreen buttons to his program. All they do is emulate within the program someone pressing 0-9, +, -, ., and enter.

                  It should be pretty self-explainatory. done is the same as pressing enter. Use is like pressing +, del is -, spc is 0, caps is .

                  If you have any questions about the onscreen buttons let me know.
                  Attached Files

                  Progress: On hold while I pay off my new PowerBook :D
                  Part List:
                  VIA MII10000 - 512MB - 20Gig 2.5" - Rikaline 6010 - 7" Lilliput - CNX-P1260 - Alpine 4ch Amp - 4 Gauge wire and fused distrobution block.

                  Comment


                  • #10
                    Good Stuff Mookie! Didnt know if there was a use for the OSK, but now that you've done it, i like it!

                    You dont need Girder to run it, but to utilise it in your applications you need something that calls it up. Any automation tool will work, you just need to be able to call my program using a keystroke (or even an icon on the QuickLaunch area if you have a touchscreen). and also you need to be able to paste the results from the clipboard. Thats all i use Girder for.

                    Actually, if you have a half-decent numpad (one of those ones with some shortcut keys on the top), you could probably use the supplied software to program those shortcut keys to call my program, and paste the results.

                    If it gets integrated into a Media Player (Confused?? ) it would allow input into any field directly. But if you run any external apps, you would still want to be able to call it seperately...


                    If some really smart people started working on it i'm sure you could get it to update the fields directly without needing to paste. I actually started looking at making my own IME for XP based on this, but stopped after the first page of the 300 page instruction manual and realised it was beyond me...

                    Comment


                    • #11
                      i just programed up my media remote to numpad buttons in girder, and it works great, it has the lettering (abc, def) under the numbers too which is really cool. one more thing though, my remote has 2-ABC, 3-DEF etc, but on this prog its 8-abc, 9-def.
                      could this be reprogramable?

                      thanks,
                      tom.

                      Comment


                      • #12
                        I will definitely be looking at this code within the next few days for integration into AIMEE I have a PS2 numberpad sitting in my shed doing nothing that fits into my armrest perfectly, this will be an awesome addition to AIMEE and my car to get it done


                        Garry
                        Co-Developer of A.I.M.E.E
                        www.aimee.cc

                        Comment


                        • #13
                          with the whole t9 thing in mind, how are you storing or planning on storing the dictionary file?

                          I was thinking that if you could store it in a tree then searching through the database would be quite quick as you can ignore a lot of words very easily by pruning every branch on the tree but the first letter typed and so on for each following letter.

                          I think thats how t9 works anyhow, just a thought
                          Project Neville: "The Brain"
                          MP3/GPS

                          Comment


                          • #14
                            Thats an interesting thought Keegan. I was just going to store the words into 37 tables (1 letter per table, 0-9, and punctuation), and query the table. Then the resultset from that gets passed into the function recursively, so each function just takes unmatched words out until you reach the end of inputted characters, or until there are no more words (at which point i plan on calling the first input applet to let you spell the words!)

                            Actually, that kind of sounds like what you are talking about, doesnt it...

                            Comment


                            • #15
                              Slight modification: This version uses the keys as they are layed out (e.g. 1 = Punctuation, 2 = abc2, 3 = def3 etc

                              I'm still working on a version which is completely customisable (allow you to enter international characters into it, or change what the +, -, . keys do as well. But its got a bit busier here at work, so it might take a bit (really should get me a version of Visual Studio at home!)
                              Attached Files

                              Comment

                              Working...
                              X