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 07-12-2013, 05:27 PM   #226
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Quote:
Originally Posted by tshering View Post
I am not sure whether I understand your problem. Maybe there is also a problem of terminology on my side. It is enough to put a dot at the beginning of the directory name, no need to set a hidden attribute. Nickel does see such directories, for instance .kobo, but it does not scan them for books.
That would be great, and there would be no need to hide the folder or the SD card. Nickel would not be dealing with a hidden folder at all, just with where it looks for books. I will try this first.

First I guess I should see how Koreader reacts to folders with a leading dot, in a FAT file system. It should have no special meaning, unless Koreader is doing something similar, which it appears it is not.

Thanks,
Ken

Last edited by Ken Maltby; 07-12-2013 at 05:43 PM.
Ken Maltby is offline   Reply With Quote
Old 07-12-2013, 07:21 PM   #227
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Well the dot foldername does keep nickel from Processing the files in the folder (it did put
a KoboExternalStorage folder in the SD root though) But Koreader doesn't show the dotfolders either. I was able to insert the SD card while in Koreader and see the folders with the leading dot removed. I also could remove the card and reboot back to Nickel with no problems. So, my "last resort" works, although I am concerned what effect using that procedure will have over time. (The external card reading hardware was a little flakey from the start.)

Well for this approach to work, Koreader needs to be made able to see .folders. I don't see why Koreader is ignoring the files, unless it is because it is not a valid FAT 32 folder naming.

Luck;
Ken
Ken Maltby is offline   Reply With Quote
 
Advertisement
Old 07-12-2013, 10:44 PM   #228
BWinmill
Wizard
BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.
 
Posts: 1,772
Karma: 15130982
Join Date: Sep 2011
Device: Sony PRS-T1
Corrected idea:

You can try adding a line between lines 20 and 21 of frontend/ui/widget/filechooser.lua. These lines are:

Code:
	for f in lfs.dir(self.path) do
		if self.show_hidden or not string.match(f, "^%.[^.]") then
It should be changed to:

Code:
	for f in lfs.dir(self.path) do
		self.show_hidden = true
		if self.show_hidden or not string.match(f, "^%.[^.]") then
It's a bit of a kludge, but it should work.

I haven't had a chance to test it since I haven't managed to get koreader to work after a factory reset (!), but there is no reason why it shouldn't work. (Just keep a backup of the original file to be safe.)

Last edited by BWinmill; 07-12-2013 at 10:53 PM.
BWinmill is offline   Reply With Quote
Old 07-12-2013, 11:57 PM   #229
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Quote:
Originally Posted by BWinmill View Post
Corrected idea:

You can try adding a line between lines 20 and 21 of frontend/ui/widget/filechooser.lua. These lines are:

Code:
	for f in lfs.dir(self.path) do
		if self.show_hidden or not string.match(f, "^%.[^.]") then
It should be changed to:

Code:
	for f in lfs.dir(self.path) do
		self.show_hidden = true
		if self.show_hidden or not string.match(f, "^%.[^.]") then
It's a bit of a kludge, but it should work.

I haven't had a chance to test it since I haven't managed to get koreader to work after a factory reset (!), but there is no reason why it shouldn't work. (Just keep a backup of the original file to be safe.)
Thanks, I'll give it a try. It looks to be not only addressing the .file issue but actual hidden file display as well.

Wondering why not change the earlier "show_hidden = false" to true?

Luck;
Ken

Last edited by Ken Maltby; 07-13-2013 at 12:03 AM.
Ken Maltby is offline   Reply With Quote
Old 07-13-2013, 12:59 AM   #230
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 5,898
Karma: 5704423
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo Touch, Kobo Glo
Quote:
Originally Posted by Ken Maltby View Post
Thanks, I'll give it a try. It looks to be not only addressing the .file issue but actual hidden file display as well.

Wondering why not change the earlier "show_hidden = false" to true?
Do you have text entry in the file browser? If so, you should be able to enter the name of the hidden folder and open it.

As to nickel, it isn't mounting the SD card. That is done in scripts at startup and when the card is detected. If you removed the mount commands from the scripts, it should solve it. The thread that PeterT pointed to should have everything. I think removing the mount commands where that thread was changing them to allow mounting ext3 file system cards.
davidfor is online now   Reply With Quote
Old 07-13-2013, 01:05 AM   #231
BWinmill
Wizard
BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.
 
Posts: 1,772
Karma: 15130982
Join Date: Sep 2011
Device: Sony PRS-T1
Quote:
Originally Posted by Ken Maltby View Post
Wondering why not change the earlier "show_hidden = false" to true?
Because I searched for self.show_hidden, so it didn't catch that occurrence.

I'm guessing that your observation is valid and is a better solution than mine. It's just a guess because I don't know much about Lua and I'm using my knowledge of other programming languages here. On the other hand, I only received two results (both in filechooser.lua) when I searched the entire directory tree for "show_hidden". I don't see how changing it in the constructor will be overridden by anything else.

Quote:
Thanks, I'll give it a try. It looks to be not only addressing the .file issue but actual hidden file display as well.
On most of the Unix systems I've dealt with, there isn't a hidden file attribute. The software uses the convention that any file starting with a dot is hidden. (This isn't true of OS X so there are exceptions. Then again, the traditional Unix utilities ignore the hidden attribute.)

Actually, the following line alludes to that:

Code:
if self.show_hidden or not string.match(f, "^%.[^.]") then
If the variable show_hidden is true, the condition is always true, so it ignores everything after the "or". However, if the variable is false it tries to match the regular expression. The regular expression matches any filename that starts with exactly one dot and is followed by a non-dot character (more characters can follow, but the regex doesn't care). If it matches the file is hidden so it won't show it. If it doesn't match, it isn't a hidden file so it will show it.

Last edited by BWinmill; 07-13-2013 at 01:18 AM. Reason: added comment on hidden files, then added more ramblings on the conditional.
BWinmill is offline   Reply With Quote
Old 07-13-2013, 01:16 AM   #232
PeterT
Taking a break; Fed up
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
PeterT's Avatar
 
Posts: 7,207
Karma: 45329895
Join Date: Nov 2007
Location: Toronto
Device: Wife: Touch, Arc, Vox Me: Nexus 7, Glo
Quote:
Originally Posted by BWinmill View Post
On most of the Unix systems I've dealt with, there isn't a hidden file attribute. The software uses the convention that any file starting with a dot is hidden.
And of course a directory entry is just another type of file, so .... it's just being consistent in treating all entries that start with a period as hidden.
PeterT is offline   Reply With Quote
Old 07-13-2013, 01:33 AM   #233
BWinmill
Wizard
BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.
 
Posts: 1,772
Karma: 15130982
Join Date: Sep 2011
Device: Sony PRS-T1
Quote:
Originally Posted by PeterT View Post
And of course a directory entry is just another type of file, so .... it's just being consistent in treating all entries that start with a period as hidden.
I remember using an older version of Unix where you could read a directory like a file, which was kinda fun. (I just tried under OS X, Linux, and NetBSD. Alas, it doesn't work on those systems.)

It also sort-of explains why you can do something like this:

Code:
$ mkdir -p 1/2/3
$ chmod 100 1
$ ls 1
ls: 1: Permission denied
$ cd 1
$ ls
ls: .: Permission denied
$ ls 2
3
Weird stuff.
BWinmill is offline   Reply With Quote
Old 07-13-2013, 01:48 AM   #234
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Well that change does let Koreader's File Manager see hidden files/folders and those with .Filename format. Nickel doesn't try to process the files on the test SD card that are in a .folder. So, it works! Now I will have to try and make a full sized uSD card with the folders behind/under a .folder.

We may finally have an AuraHD that can have a truly large collection of ebooks in defined category folders, that can contain files in a larger number of formats, all readable with Koreader. At the same time we can use calibre to load the internal uSD card with files easily processed by Nickel. The best of both worlds and with your hack their will be no conflicts.

Thanks;
Ken

OK, it is working fine with a larger file structure. All good to go. If only the File Manager had larger text and larger easier to select active points. It would be just right, for me.

Last edited by Ken Maltby; 07-13-2013 at 02:49 AM.
Ken Maltby is offline   Reply With Quote
Old 07-13-2013, 03:01 AM   #235
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
I had to Google around to find out how to get win7 "Rename" to allow me to create a folder with a leading dot. It turns out that if you put a dot in front and one in back of your folder name, it will accept it and the dot in back will be removed, leaving you with a ".folder".

Luck;
Ken
Ken Maltby is offline   Reply With Quote
Old 07-13-2013, 03:23 AM   #236
BWinmill
Wizard
BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.BWinmill ought to be getting tired of karma fortunes by now.
 
Posts: 1,772
Karma: 15130982
Join Date: Sep 2011
Device: Sony PRS-T1
Try changing line 96 of frontend/ui/widget/menu.lua from:

Code:
face = Font:getFace("cfont", 22),
To:

Code:
face = Font:getFace("cfont", 28),
BWinmill is offline   Reply With Quote
Old 07-13-2013, 05:34 AM   #237
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Quote:
Originally Posted by BWinmill View Post
Try changing line 96 of frontend/ui/widget/menu.lua from:

Code:
face = Font:getFace("cfont", 22),
To:

Code:
face = Font:getFace("cfont", 28),
I tried 28 but that was a little too big and too much of the titles were pushed off screen, so I changed them back to 24 which is about as big as I find practical.

Thanks, again;
Ken
Ken Maltby is offline   Reply With Quote
Old 07-13-2013, 06:54 AM   #238
Markismus
Disjunctive Undecidedness
Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.Markismus has top level security clearance to Area 51.
 
Markismus's Avatar
 
Posts: 305
Karma: 94594
Join Date: Jul 2013
Location: Netherlands
Device: Cracked Kobo Aura HD, Cracked Kobo Aura, Kobo Aura H2O
Quote:
Originally Posted by BWinmill View Post
Try changing line 96 of frontend/ui/widget/menu.lua from:
Code:
face = Font:getFace("cfont", 22),
To:
Code:
face = Font:getFace("cfont", 28),
It works. On line 70 is the fontface for the exit -[ X ]-. And on line 210 there is amongst others the fontface for the menu title.

It works, but you get the same empty line through your letters as you would get when you change the return dpi for the Aura to 265 (in screen.lua, line 101).

Even after changing the menutitle to 35( menu.lua, after line 210) I seldom get the filemanager dropdown menu. Even after changing the -[X]- font to 32 (menu.lua, after 70) it does not exit reader.lua.

Anyone have an idea how to get rid of the inverse strikeout? Any idea how to get the Aura more responsive to tapping the text?
Markismus is offline   Reply With Quote
Old 07-13-2013, 05:17 PM   #239
Ken Maltby
Wizard
Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.Ken Maltby ought to be getting tired of karma fortunes by now.
 
Ken Maltby's Avatar
 
Posts: 2,931
Karma: 3910173
Join Date: Dec 2009
Location: The Heart of Texas
Device: JetBook Lite, AuraHD, PDA, Eee Transformer
Quote:
Originally Posted by Markismus View Post
It works. On line 70 is the fontface for the exit -[ X ]-. And on line 210 there is amongst others the fontface for the menu title.

It works, but you get the same empty line through your letters as you would get when you change the return dpi for the Aura to 265 (in screen.lua, line 101).

Even after changing the menutitle to 35( menu.lua, after line 210) I seldom get the filemanager dropdown menu. Even after changing the -[X]- font to 32 (menu.lua, after 70) it does not exit reader.lua.

Anyone have an idea how to get rid of the inverse strikeout? Any idea how to get the Aura more responsive to tapping the text?
I'm not sure there is a connection between the font size and the active selection area on the touchscreen. The "empty line" may be an artifact of some such relationship, (just a supposition) but it should not be there, there must be a way to present the text without it.

I tried a larger -[X]- too and it didn't change how I had to poke the screen to get it to work. I still had to roll my digit off the edge of the Bezel and push up into the bezel, to shape my fingertip or edge of my thumb into what was needed to activate that selection. I have to do much the same between "File" and "Manager" of the title to some times get the dropdown menu.

I think I remember Giorgio saying that he had changed dpi in his latest port, posted in the first post of this thread. I have that one running now and it is functioning very well. I used the koreader_kobo.sh that Giorgio posted to Koreader Github, before he went on holiday.

Luck;
Ken
Ken Maltby is offline   Reply With Quote
Old 07-13-2013, 06:03 PM   #240
paola
Wizard
paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.paola ought to be getting tired of karma fortunes by now.
 
paola's Avatar
 
Posts: 2,778
Karma: 5324790
Join Date: Oct 2010
Location: UK
Device: Pocketbook Pro 903, (beloved Pocketbook 360 RIP), Kobo Mini, Kobo Aura
Quote:
Originally Posted by Markismus View Post
The dictionary is working in the 273 version on the Aura!! Even better the german dictionary is working using the Duden files from Stardict.
great, any one tried it on other devices? I am interested in the Mini, and of course I hear you say I could try myself, but as I am lost in the technical talk, I can't keep track of which is the latest version, whether it includes all mods (I think it does not), and in which order the various things should be installed.
Yes, there is a post which explains this, but it is older than subsequent modifications (I think..)
paola 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
Native KOReader: a document reader for PDF, DJVU, EPUB, FB2, HTML, ... (GPLv3) hawhill Kindle Developer's Corner 643 Yesterday 05:54 PM
2 kobos at once tsarinaerika Kobo Reader 14 06-03-2013 05:13 AM
Syncing between two Kobos fx3000se Kobo Reader 4 01-24-2013 03:10 PM
Touch Using two Kobos tkavan Kobo Reader 2 09-15-2012 09:37 PM
2 kobos 1 account retired05 Kobo Reader 9 05-05-2012 09:25 AM


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


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