Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 11-23-2012, 02:52 PM   #91
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
Tshering

From this moment I'm in the fourth dimension.

I'll slowly slowly
gouni is offline   Reply With Quote
Old 11-23-2012, 03:47 PM   #92
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 1,301
Karma: 337944
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by gouni View Post
From this moment I'm in the fourth dimension.
Does this mean you are now enlightened? Confused? Happy? Motivated?

Don't forget to make back ups of your files after every step. In case something goes wrong (and this will certainly happen at one point or another) you can always return to your last back up, rather than start the whole work anew.

Which text editor do you use? For replacing some text by some other text almost any editor will do (for instance the simple "Editor" of Microsoft); for replacing line breaks by something you need another tool. If you have MS word you can use it. I guess notepad+ can also do it.
tshering is offline   Reply With Quote
Old 11-23-2012, 04:07 PM   #93
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
I am all at once. I have never done that.

I use my windows notepad.

I'll install notepad +

I'll go little by little, I will put a year but I'll.

My cat tells me I'll go faster by learning the dictionary upside down.


Last edited by gouni; 11-23-2012 at 04:10 PM.
gouni is offline   Reply With Quote
Old 11-23-2012, 05:04 PM   #94
ShellShock
Guru
ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.
 
ShellShock's Avatar
 
Posts: 892
Karma: 1642544
Join Date: Sep 2008
Device: Sony PRS-505 & PRS-650, Kobo Glo & Aura HD
Quote:
Originally Posted by tshering View Post
The description of which words go into the 11.html file might easily be misunderstood. Actually, a word/expression goes there if the first or/and second character is not a letter. Examples for the second character being not a letter are <a name="I'd">, <a name="o'clock">, <a name="T4 cell">.

Maybe it would be good to shift the whole explanation about CR and LF to point 3. I do not think that CRs in the html prevent correct processing or displaying, and they have no connection with the index file. On a side note, in the original dicthtml, CR and LF are both omitted, presumably because of performance concerns.
Thanks very much for this; especially the point about first or second characters not being a letter means using 11.html, which I did not realise. I need to go back and update my dictionaries to take that into account.
ShellShock is offline   Reply With Quote
Old 11-23-2012, 05:49 PM   #95
ShellShock
Guru
ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.ShellShock ought to be getting tired of karma fortunes by now.
 
ShellShock's Avatar
 
Posts: 892
Karma: 1642544
Join Date: Sep 2008
Device: Sony PRS-505 & PRS-650, Kobo Glo & Aura HD
Actually, in my dictionary "o'clock" is defined in o'.html, and the lookup works fine. So I am not convinced about this second character business and having to use 11.html. Maybe it works either way?
ShellShock is offline   Reply With Quote
Old 11-23-2012, 05:58 PM   #96
Koboyashi
Zealot
Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.
 
Posts: 135
Karma: 207434
Join Date: Dec 2011
Device: Kobo Touch & Glo
Quote:
Originally Posted by gouni View Post
... I use my windows notepad. I'll install notepad + ...
Notepad++ is a fine tool. Especially to edit files from a linux device under windows easily.
Here you go: http://notepad-plus-plus.org/
Koboyashi is offline   Reply With Quote
Old 11-23-2012, 07:09 PM   #97
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 1,301
Karma: 337944
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by ShellShock View Post
Actually, in my dictionary "o'clock" is defined in o'.html, and the lookup works fine. So I am not convinced about this second character business and having to use 11.html. Maybe it works either way?
Could well be. I only reported what I found in the 11.htmls of the Kobo dictionaries. Maybe only those words with the first or second letter being forbidden in filenames must go to the 11.html, and some other cases are optional.
tshering is offline   Reply With Quote
Old 11-24-2012, 02:36 AM   #98
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
Kobojashi
gouni is offline   Reply With Quote
Old 11-24-2012, 07:49 AM   #99
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
Quote:
Originally Posted by tshering View Post
gouni, You can try this:

To get minimal formatting replace line breaks by <br/>
I do not know to do this

I use your notepad +++ which is wonderful.

At the end of the line I have a LF in black, it is the function to replace it with <br/> ?

Thanks for your help
gouni is offline   Reply With Quote
Old 11-24-2012, 08:01 AM   #100
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 595
Karma: 1281565
Join Date: Dec 2011
Location: Padova, Italy
Device: Kindle3, Odyssey, eDGe, A60, PRS-T1, iPad3, KoboGlo
I guess tshering's suggestion is to use:

Code:
<p>First phrase.<br/>Second phrase.</p>
instead of

Code:
<p>First phrase.</p><p>Second phrase.</p>
to gain some typographical space on the device screen.
AlPe is offline   Reply With Quote
Old 11-24-2012, 09:15 AM   #101
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
I don't understand

I have this on the screen with notepad +++

http://www.mediafire.com/?5g5y2pam055olvg

Last edited by gouni; 11-24-2012 at 09:26 AM.
gouni is offline   Reply With Quote
Old 11-24-2012, 12:17 PM   #102
Koboyashi
Zealot
Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.Koboyashi ought to be getting tired of karma fortunes by now.
 
Posts: 135
Karma: 207434
Join Date: Dec 2011
Device: Kobo Touch & Glo
This is from your example pic:



The black'n white "LF" comes from Notepad++, its a config thingy to show you the normally invisible line feeds in
the editor window. The file content itself is not affected. For a Linux file it is only "LF", for Windows it's "CRLF" and
for Mac it's "CR".

Notepad++ recognizes the line feeds of a file automatically and will keep them while saving. Please do never use
the small Notepad delivered with Windows to edit Linux text files.

You may toggle the visibility of the line feeds as follows:
French: View -> Show Symbol -> Afficher les symboles de fin de ligne
English: View -> Show Symbol -> Show End of Line

Last edited by Koboyashi; 11-24-2012 at 12:26 PM.
Koboyashi is offline   Reply With Quote
Old 11-24-2012, 12:33 PM   #103
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
Thank Koboyashi.


I chose the end of line feed LF as shown above.



I think I'll now move to the next step

Create a dictionary with a few words and see if it works.


It is thrilling.
gouni is offline   Reply With Quote
Old 11-24-2012, 01:39 PM   #104
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 1,301
Karma: 337944
Join Date: Jun 2012
Device: kobo touch
Congratulations! Your dicitonary file looks good. Does your sample dictionary already work?
You will see that the whole definition is in one block without any formatting and difficult to read. I thought it might be nice to add a minimal formatting. One easy way would be by replacing all LF by <b/>. In the replace box of notepad++ select "Search mode: extended." You can search LF by "\n".

Code:
Find what: \n
Replace with: <b/>
This will give you, for instance

Quote:
Synonymes :<b/> - aveuli<b/> - mou<b/> - ramolli<b/> - se relâcher<b/>
But it will give you also </w><b/>. This however we do not want, therefore we replace </w><b/> by </w>.

The drawback of this formatting is that it uses a lot of space on the screen, and you will probably have to go through several pages in order to read the definition of an entry. Therefore, it maybe better to replace the LF by something else that gives you a hint about the the structure of the information, maybe "||" or any good visible symbol.

Another thing: When producing the index file choose for encoding "encode in UTF-8 without BOM". If you choose "encode in UTF-8" the first line will not be taken into account by the dictionary engine.

Last edited by tshering; 11-24-2012 at 01:41 PM.
tshering is offline   Reply With Quote
Old 11-24-2012, 02:17 PM   #105
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
I have just read to you. tshering

I have a long time before you understand how to run a command by windows for marisa.

I'll redo with utf8-bom I had a - 1 to my first and last index entry.

At the moment I am testing marisa it build and marisa lookup.

My eyes are like those of my cats at night.

I learn while on the job, I have the head that heats.


I start again with the right encoding


I had on my five-word index with marisa lookup

-1 1 2 3 -1

with utf8-bom i have

1 2 0 3 -1

I have a bug I can do

Last edited by gouni; 11-24-2012 at 02:27 PM.
gouni is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What's file format of dictionary mnjkl Kobo Reader 2 12-12-2011 08:48 AM
Dictionary format jgray Sony Reader 1 10-25-2010 09:52 AM
English Thesaurus in the dictionary format osnova Amazon Kindle 14 12-12-2009 06:42 PM
Dictionary: what version? can it be in firmware? jedix Sony Reader Dev Corner 7 12-05-2008 12:00 PM
Webster dictionary in DEPReader format abigail Reading and Management 0 08-10-2005 08:00 AM


All times are GMT -4. The time now is 03:10 AM.


MobileRead.com is a privately owned, operated and funded community.