Page 5 of 6 FirstFirst 123456 LastLast
Results 41 to 50 of 58
Discuss [Keyboard] Dictionary editor for 1.1.1 and later at the Tools - Hackint0sh.org; Okay, you can find the script at: http://www.artdstract.pl/iphone/dictionary.phps Use it in the same manner as ...
  1. #41
    Advanced Array

    Join Date
    Dec 2007
    Posts
    44
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Okay, you can find the script at: http://www.artdstract.pl/iphone/dictionary.phps

    Use it in the same manner as two_letter script (instructions above). The only diffrence is, that frequencies range from ~10 to ~10000. Where frequency < 1000 means most common used words.

    These frequencies can be found in some ispell wordlists.

    Like I said, the script is imperfect. It can't parse other characters than latin ones. Other than that you can generate valid dictionary files with it, with big success rate .


  2. #42
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Quote Originally Posted by M4v3R View Post
    You can edit one-letter-words file by hand. There are 52 records there - for 26 for big and 26 for small letters. Replacement for 'A' is at offset 0x0B (11 in decimal), for 'B' - 0x11 (17 in decimal), and so on. Replacement for 'a' is at 0xA7, 'b' at 0xAD, 'z' at 0x13D. I think you get the picture .

    Big letters aren't replaced in en_US file, this is probably because you write shortcuts and abbreviations in big letters mostly, so they don't need to be replaced. Small letters, however, are replaced when you type wrong one. For eg. 'z' is replaced to 'a', and 'i' is replaced to 'I' (big 'i', as in english grammar).
    Sorry, I don't understand.

    1) How is the one-letter-words.dat file used?

    2) What changes needs to be done in the one-letter-words file? Should it always be 52 records, or is it possible to add , and ?

  3. #43
    Advanced Array

    Join Date
    Dec 2007
    Posts
    44
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    It's used for suggesting one letter words . No, You can't add more records to it, as far as I know.

  4. #44
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Quote Originally Posted by M4v3R View Post
    Okay, you can find the script at: http://www.artdstract.pl/iphone/dictionary.phps
    I've found a bug

    if ( strpos ( $stem, $letters[0] ) !== false || strpos ( $stem, $letters[0] ) !== false || strpos ( $stem, $letters[0] ) !== false )

    should be

    if ( strpos ( $stem, $letters[0] ) !== false || strpos ( $stem, $letters[1] ) !== false || strpos ( $stem, $letters[2] ) !== false )
    Last edited by kia; 01-06-2008 at 10:29 AM.

  5. #45
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Ignore. I was wrong.
    Last edited by kia; 01-06-2008 at 10:29 AM.


  6. #46
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Quote Originally Posted by M4v3R View Post
    - 2 bytes: letter count. It's encoded in a weird way, can be calculated with formula: 0x821 + (0x421 * letter count in word). Don't ask why, it's just it .
    In your php code you use this algorithm:

    pack ( "v", 0x400 + ( 0x421 * strlen ( $word['word'] ) ) )

    I notice that this differs from your first info. Can you tell me how (not why ) you found this algorithm?

    I've almost got a working dictionary that supports unicode. But it all fails at the above algorithm, which doesn't seem to be working when word is unicode. If you have more info about this algorithm it would be very helpful!

    Edit: I'll try to add some info myself
    The word "über" which is unicode for ber have the length a414 (hex) in the de_DE-unigrams.dat file. But when calculating the same value using your algorithm I get a different value.
    Last edited by kia; 01-06-2008 at 11:22 AM.

  7. #47
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    If it is a utf8 word, then this is the algorithm to use:

    0x400 - 0x401 + ( 0x421 * letter count in word )

  8. #48
    kia
    kia is offline
    Rookie Array

    Join Date
    Oct 2007
    Posts
    24
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Quote Originally Posted by M4v3R View Post
    Edit: You can edit one-letter-words file by hand. There are 52 records there - for 26 for big and 26 for small letters. Replacement for 'A' is at offset 0x0B (11 in decimal), for 'B' - 0x11 (17 in decimal), and so on. Replacement for 'a' is at 0xA7, 'b' at 0xAD, 'z' at 0x13D. I think you get the picture .

    Big letters aren't replaced in en_US file, this is probably because you write shortcuts and abbreviations in big letters mostly, so they don't need to be replaced. Small letters, however, are replaced when you type wrong one. For eg. 'z' is replaced to 'a', and 'i' is replaced to 'I' (big 'i', as in english grammar).
    One letter words suggestions seems only to be working when language is english. When using german or swedish I dont get any suggestions at all. Not even when renaming the original german one-letter-words file to en_US-one-letter-words.dat.
    Last edited by kia; 01-08-2008 at 10:23 PM.

  9. #49
    Advanced Array

    Join Date
    Dec 2007
    Posts
    44
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Err... I'm not quite sure how I discovered it - it just came to me when I wrote down all possible values and letter counts and was looking at it. PHP strlen() function doesn't handle unicode properly - it will count every utf8 character twice. Hence the error. See http://pl2.php.net/strlen, in comments there is a function that does it properly.

  10. #50
    Newbie Array

    Join Date
    Jan 2008
    Posts
    2
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    Hi,

    Thanks for all the work made it...

    Someone has one/two letters spanish files?

    Thanks in advance.

    colgaooo


 

 
Page 5 of 6 FirstFirst 123456 LastLast

Similar Threads

  1. MacNN: Sena Keyboard Folio for iPad includes built-in keyboard
    By hackint0sh in forum Latest Headlines
    Replies: 0
    Last Post: 08-30-2010, 09:20 PM
  2. Dictionary Eng -> Spa
    By MrtynKyn in forum AppStore Software
    Replies: 0
    Last Post: 07-11-2009, 03:43 AM
  3. Replies: 2
    Last Post: 01-13-2009, 06:20 PM
  4. [Dictionary] Virtual keyboard
    By MaLer in forum General
    Replies: 28
    Last Post: 04-07-2008, 10:21 AM
  5. Dutch keyboard / dictionary ?
    By ExOMaNiaC in forum General
    Replies: 16
    Last Post: 11-28-2007, 05:38 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Powered by vBulletin®
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Search Engine Friendly URLs by vBSEO
(c) 2006-2012 Hackint0sh.org
All times are GMT +2. The time now is 03:57 PM.
twitter, follow us!