2
0
mirror of https://github.com/koreader/koreader synced 2024-10-31 21:20:20 +00:00
Commit Graph

103 Commits

Author SHA1 Message Date
Tigran Aivazian
30de5e0a23 Initial commit of picviewer. 2012-10-08 16:39:03 +01:00
Tigran Aivazian
87712cf0e4 Show the program version in the Help header.
1. On startup read the file git-rev if exists and initialize a new global
G_program_version.
2. In filechooser's help page's header show the version.
This helps to easily identify what version the user is running without
asking him to cat git-rev file manually.
2012-10-07 12:59:37 +01:00
NuPogodi
00c1f2ec9c New InfoMessage Concept
Part I (still no unireader, crereader, filesearcher & fileinfo)
2012-10-03 00:45:45 +02:00
Tigran Aivazian
bc3c3f6a38 Oops, left the pointer to emulator binary, sorry. 2012-09-25 16:56:42 +01:00
Tigran Aivazian
96ac2bef8d Simplify the calling of filechooser.
The FileChooser:choose() method returns only a single argument,
so we can get rid of the second return value in reader.lua and
simplify the code a bit.
2012-09-25 16:54:37 +01:00
Tigran Aivazian
1a119660ea Display better messages on failing to open a file.
1. Usually the error messages from the :open() method are too
long (except for crereader files) and won't be shown.
So, I extract the first 30 bytes from the error message (if there is
one) and show that. But if there is no error message then just display
the generic "Error opening document ". Otherwise, as was currently the
case, the error message is present but is too long and so we get
absolutely nothing, not even a generic one. But in the Debug output we
can show the entire error message as there is no restriction on the
length.
2. Use showInfoMsgWithDelay() instead of InfoMessage:show() followed by
util.sleep().
3. Remove the dependency on keys.lua. This was needed when we were
detecting emulation by comparing the physical value of some KEY_ but now
we use util.isEmulated() so there is no need for it anymore.
2012-09-25 13:48:21 +01:00
Tigran Aivazian
416c62ca61 Tidy up debug support.
1. Make "-d" switch passed to reader.lua enable all debugging
2. Enable debugging for now (development stage) to preserve the current
behaviour. But for the production release I advise to: a) disable it by
not passing "-d" and b) redirect standard output (not just standard
error) of reader.lua to crash.log in kpdf.sh
3. Comment out debug printf()s in pdf.c
2012-09-25 13:11:21 +01:00
Tigran Aivazian
b297ee2c71 Use generic FileExists()
This change should have been in the previous commit, sorry.
2012-09-25 12:24:48 +01:00
Tigran Aivazian
47556b5562 Shorten the message about opening the document, otherwise it is not displayed at all. 2012-09-10 00:16:06 +01:00
Dobrica Pavlinusic
406f3d72da fallback to default fonts when loading reader configuration
Since we are adding and renaming fonts, we need to make sure that
all fonts which reader uses are defined. This allows us to add fonts
and not break when users load old configuration files

close #252
2012-09-07 16:29:52 +02:00
NuPogodi
b052e3207c Add global parameter filemanager_expert_mode
In order to switch between safe and advanced way for filechooser to manage files, I've introduced special parameter 'filemanager_expert_mode':
i) 'safe' means that filemanager shows only files with the reader-related extentions; make safe renaming (i.e. the extention remains the same)
ii) 'advanced': all files are available (no filtering); any renaming is allowed;
TODO: to add also 'expert' mode & use it for unstable or dangerous functions
2012-09-06 21:38:54 +03:00
NuPogodi
a1c85affd1 if the document cannot be opened, function openFile(filename) shows a warning with specified error 2012-09-05 19:53:37 +03:00
Qingping Hou
2485a552eb first try to fix #127 2012-06-07 23:39:28 +08:00
HW
906a5bd48c removed debugging cruft 2012-06-04 00:53:24 +02:00
HW
0d12ff70cd rename debug() to Debug() to stop clashing with the debug submodule from Lua 2012-06-04 00:49:23 +02:00
HW
02c40b6078 configurable default font for CREngine
when in CREngine mode, the current font can be made the default
document font by pressing Shift-F

in order to store this setting, the reader_settings variable was
promoted to the declared global G_reader_settings

close #184
2012-06-02 23:51:55 +02:00
NuPogodi
3a76ec91fd integrate rest of @NuPogodi changes #166
- long lines (filenames in 'Document Info') are now splitted in more
  human-readable way (by spaces, dots, slashes or some other characters
- see screenshot)
- the selection of fonts in filemanager (key 'F' or 'Aa') looks now more
  user-friendly
- fixed too long strings in most menues (TOC, Bookmarks, Fonts...) and
  in the popup with the reading progress (called by key 'Menu')
- the position inside the cr-documents (epub, mobi...) now remain nearly
  the same after rescaling the document (i.e. changing the font face,
  size, boldface and interline distance)
- when you open TOC-menu or Fonts Menu, it highlights the current item
  (i.e. current chapter and current fontface).
- i've a bit changed the way to read the battery level values, it might
  now work even without Amazon Kindle framework.
2012-05-19 13:04:49 +02:00
Dobrica Pavlinusic
ba19ab7029 added .prc as alternative extension for mobi
This was reported by @valex in post at forum:
http://www.mobileread.com/forums/showpost.php?p=2064360&postcount=340
2012-05-01 19:24:52 +02:00
Qingping Hou
a89c88f40f add zip format support 2012-04-24 20:44:59 +08:00
Qingping Hou
dbb49505f1 add doc format support
Though I don't like doc at all.
2012-04-24 20:37:16 +08:00
Dobrica Pavlinusic
18f0cf8043 added mobi to CREReader #131 2012-04-21 14:18:23 +02:00
Qingping Hou
b03d589ae9 add preLoadSettings methods for cache_document_size setting
cache_document_size should be configurable for
every docuemnt and it must be loaded before
document open, so I added the preLoadSettings method
2012-04-19 14:39:50 +08:00
Qingping Hou
c4bd2a1046 add debug argument to reader.lua
Without -d argument, all the debug message will
be suppressed.
2012-04-19 11:05:48 +08:00
Qingping Hou
3306346dba use debug to print debug info 2012-04-19 00:16:49 +08:00
Qingping Hou
1b2d0b71b0 fallback to stop framework approach on screensaver fix 2012-04-18 19:43:55 +08:00
Qingping Hou
fa414af1eb handle obselete jumpstack settings
* remove jumpstack settings if found
* add DocSettings:delSetting method
* rename DocSettings:savesetting to
  DocSettings:savesetting.
2012-04-18 17:29:27 +08:00
Qingping Hou
84fe9f49a4 rewrite jump stack and add bookmark feature
* jump stack is rewritten as jump history
* add bookmark feature
2012-04-18 17:01:22 +08:00
Dobrica Pavlinusic
065d68c3a5 use refresh_mode 2012-04-16 21:55:18 +02:00
Qingping Hou
5e867d38ef show infomessage on document open 2012-04-15 14:20:26 +08:00
HW
676e4268ff display document open error message 2012-04-15 02:34:09 +02:00
HW
ec2eda0c05 switched font handling to only work with external fonts
now you can use a environment variable, FONTDIR, to point
to a font dir. Otherwise, "./fonts" is used by default.
Subdirectories are indexed.
2012-04-09 19:04:26 +02:00
HW
a824204039 fixed missed case for device/emu recognition 2012-04-09 16:32:19 +02:00
HW
caefddb99c Merge branch 'master' of github.com:hwhw/kindlepdfviewer
Conflicts:
	crereader.lua
2012-04-09 12:36:28 +02:00
HW
877ecdfb71 switched slider handling to a fork()ed process 2012-04-09 12:29:13 +02:00
Qingping Hou
ecd56a3745 mod: prefix global variables width and height with G_ 2012-04-09 15:42:19 +08:00
Qingping Hou
1f9efe0d9c Merge branch 'master' into epub
Conflicts:
	Makefile
	unireader.lua
2012-04-07 23:09:57 +08:00
Qingping Hou
9d11916bbd mod: resume framework in kpdf.sh 2012-04-07 10:05:27 +08:00
Qingping Hou
c41e3e75a3 add: demo for fixing #85, #86 2012-04-06 13:51:37 +08:00
Qingping Hou
1593c56803 mod: add html support in crereader 2012-04-05 10:31:31 +08:00
Qingping Hou
37dfc84d5a fix: move commands initilization from global init to local
If we call addAllCommands in initGlobalSettings, all
the readers will share the same commands and we cannot
adjust commands for a specific reader. I thus moved this
method call to Unireader:init() method.
2012-03-30 14:10:04 +08:00
Qingping Hou
8a2b86e203 mod: factor last reading page saving and resotring 2012-03-30 13:07:48 +08:00
Qingping Hou
b09110a38d Merge branch 'djvu-highlight' into epub 2012-03-29 17:54:48 +08:00
Qingping Hou
4821f10dda half done demo for crengine 2012-03-29 00:09:26 +08:00
Qingping Hou
46f171df3b Merge branch 'master' of github.com:hwhw/kindlepdfviewer into djvu-highlight
Conflicts:
	unireader.lua
2012-03-21 10:52:51 +08:00
traycold
bfcad367bb using font module for getting fonts (commit f95231d789)
renamed function names using camelCase (issue #62)
2012-03-20 20:15:24 +01:00
traycold
fd6c6dbe60 Merge remote branch 'hwhw/master'
* hwhw/master:
  Password input, handling for broken documents
  factored pages count out, better error and password handling
  factored pages counter out of document struct
2012-03-20 18:40:43 +01:00
Qingping Hou
f4ea1cdb62 Merge branch 'master' of github.com:hwhw/kindlepdfviewer into djvu-highlight
Conflicts:
	blitbuffer.c
	unireader.lua
2012-03-20 10:36:35 +08:00
HW
7e3e38be62 Password input, handling for broken documents 2012-03-20 00:10:19 +01:00
traycold
c2fe6f9bee Merge remote branch 'hwhw/master'
* hwhw/master:
  make muPDF cache size configurable from Lua
  add XPS and CBZ support (muPDF provides this)
  fixed bug for odd rendering widths
  refactored muPDF integration to use strictly the fitz.h API
  forgot Makefile change when factoring out drawcontext
2012-03-19 23:21:23 +01:00
HW
48463d4739 add XPS and CBZ support (muPDF provides this) 2012-03-19 22:35:16 +01:00