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

1323 Commits

Author SHA1 Message Date
Tigran Aivazian
7d53f8d34c Set show_links_enable=false by default for DjVu 2012-10-12 23:37:38 +01:00
Tigran Aivazian
dc52f81ec6 Update the message in the help screen for Shift-L 2012-10-12 23:29:49 +01:00
Tigran Aivazian
f5ac464369 Override some of UniReader's defaults in PICViewer
For the picture viewer we want to disable showing grey boxes on page
overlaps and underlining of the links (because there aren't any).
2012-10-12 19:43:42 +01:00
Tigran Aivazian
a354d96ab8 Two bugfixes and a cleanup
1. When loading boolean settings we have to explicitly check for the
return of nil from the self.settings:readSetting() function and only
modify the default if the return value is NOT nil.

2. When closing the document we have to reset the settings to defaults,
otherwise their values are re-used on the next open.

3. The messages "Links on page ON/OFF" changed to
"Link underlines ON/OFF" because the old version gave two false
impressions: a) as if the action is pertinent only to the current page
(but in fact it is global for the entire document) and b) that we are
disabling the links whereas we are only disabling the show of underlines
under the links. The new message addresses both issues.
2012-10-12 19:39:22 +01:00
Dobrica Pavlinušić
78c9223897 Merge pull request #428 from tigran123/pic-fmt
Factor out JPEG support into a module
2012-10-12 06:39:03 -07:00
Dobrica Pavlinušić
f58de262a6 Merge pull request #430 from tigran123/clipboard
Bugfix for the issue #429
2012-10-12 06:38:10 -07:00
Tigran Aivazian
daeb7ae7c8 Comment out [currently] unused variables. 2012-10-12 10:55:46 +01:00
Tigran Aivazian
8953cc89f6 Bugfix for the issue #429
The function FileChooser:FullFileName() was calculating the position of
the item incorrectly, i.e. would work only on the first page in
filechooser. This would break copying/moving files to clipboard and also
renaming files from the second page and subsequent ones.
2012-10-12 10:21:55 +01:00
Tigran Aivazian
aa2b21aa23 Recognize the files with ".jpeg" extension 2012-10-12 09:44:19 +01:00
Tigran Aivazian
a1f9068d5b Factor out JPEG support into a module
This is to make adding support for new formats easier.
See the file pic_jpeg.h for the description of the interface that each
image format must support.
2012-10-12 09:36:08 +01:00
{Qingping,Dave} Hou
b6218b30a3 Merge pull request #424 from tigran123/wrong-dotdot
Two bugfixes: issues #419 and #420
2012-10-11 22:17:56 -07:00
{Qingping,Dave} Hou
0c4f94dd19 Merge pull request #426 from tigran123/colour-jpeg
Free raw_image if it is unsupported.
2012-10-11 22:17:32 -07:00
Tigran Aivazian
2ca5c028c1 Initialize doc->image in openDocument
This is needed to protect against double free() in closeDocument().
2012-10-11 22:54:04 +01:00
Tigran Aivazian
b63edfca1f Free raw_image if it is unsupported.
If the number of colour components is neither 1 nor 3 we should remember
to free the buffer holding the raw decoded image before returning the
error to Lua.
2012-10-11 22:34:18 +01:00
{Qingping,Dave} Hou
127a20146b Merge pull request #425 from tigran123/colour-jpeg
Add support for colour JPEG images.
2012-10-11 14:31:57 -07:00
Tigran Aivazian
669d84df18 Show the number of colour components via Menu. 2012-10-11 22:22:45 +01:00
Tigran Aivazian
f0511ff22c Make closeDocument() re-entrant. 2012-10-11 22:19:33 +01:00
Tigran Aivazian
5823ab0c44 Slight tidy-up of the code. 2012-10-11 22:10:02 +01:00
Tigran Aivazian
2d2e2b6216 Add support for colour JPEG images.
I used the luminance match algorithm for converting RGB colour images to
grayscale as it gives the best visual results (but at the cost of speed).
2012-10-11 22:01:26 +01:00
Tigran Aivazian
4f16f1d97e Tidy up a comment to be consistent. 2012-10-11 20:58:10 +01:00
Tigran Aivazian
51b3d70165 Two bugfixes: issues #419 and #420
1. Rewritten the function FileChooser:setPath() to handle returning to
the parent directory via ".." entry correctly. Issue #419

2. Fixed the crash when moving the last file from a directory to the
clipboard via Shift-X and then pressing Shift-X on the phantom entry
that is left. Issue #420
2012-10-11 20:42:52 +01:00
{Qingping,Dave} Hou
5f1ce0e82d Merge pull request #421 from tigran123/pdf-cleanup
Commented out debug-only function readable_fs().
2012-10-11 06:36:20 -07:00
Tigran Aivazian
d86944cce0 Commented out debug-only function readable_fs(). 2012-10-11 11:49:38 +01:00
{Qingping,Dave} Hou
b74347afae Merge pull request #418 from tigran123/shell
Force the use of bash in the Makefile.
2012-10-10 16:46:17 -07:00
{Qingping,Dave} Hou
6bb497cfae Merge pull request #415 from tigran123/git-ignore
Add git-rev file to .gitignore
2012-10-10 16:38:30 -07:00
{Qingping,Dave} Hou
fe62c577b0 Merge pull request #412 from tigran123/djvu-gwidth
Use the local copy of the global G_width variable.
2012-10-10 16:34:54 -07:00
Tigran Aivazian
8ab0e7fcb8 Force the use of bash.
On some distributions (e.g. Ubuntu) the shell used for scripts is dash,
not bash and we explicitly rely on bash's features in the Makefile, so
we must guarantee that we are running with bash (not dash or anything
else).
2012-10-10 21:04:47 +01:00
Tigran Aivazian
f2c17ed435 Merge pull request #416 from kai771/show_links_enable
Implements a toggle that allows enabling/disabling links underlining
2012-10-10 12:20:44 -07:00
kai771
286f7caf2d "page links" -> "page links shortcut keys" 2012-10-10 21:14:02 +02:00
Tigran Aivazian
a5cd590e39 Add git-rev file. 2012-10-10 19:49:50 +01:00
kai771
bb899cfad2 Implements a toggle that allows enabling/disabling links underlining 2012-10-10 20:36:51 +02:00
Dobrica Pavlinušić
cdbacebd06 Merge pull request #411 from tigran123/picviewer
Picture viewer (currently supports only grayscale JPEG files)
2012-10-10 11:14:48 -07:00
Tigran Aivazian
148d92037e Revert "Undo some of my changes to rendertext.lua"
This reverts commit edd347eb55.
2012-10-10 17:32:23 +01:00
Tigran Aivazian
98898dabda Merge branch 'master' into picviewer 2012-10-10 17:31:39 +01:00
Tigran Aivazian
2b04e5ee86 Merge pull request #414 from hwhw/hwhw-master
Fix for blitbuffer.c / boundary checking
2012-10-10 09:23:29 -07:00
HW
b5bc152c3d Merge remote-tracking branch 'origin/master' into hwhw-master 2012-10-10 18:02:17 +02:00
HW
10806074b8 factored out blitting constraints check in a seperate function
the checking of the boundaries when blitting was incomplete
for the addblitToBuffer() function when compared with the
blitToBuffer() function. Factored out the redundant checking
procedure into a new function.

Should fix another bug leading to issue #401 and probably
more cases for specifying boundary boxes.
2012-10-10 17:58:31 +02:00
Dobrica Pavlinušić
31c10f09e7 Merge pull request #413 from hwhw/hwhw-master
added framework to check the involved pointers in blitbuffer operations
2012-10-10 08:33:52 -07:00
HW
4810eded5c added framework to check the involved pointers in blitbuffer operations
blitbuffer operations in 4bpp can be a nasty experience, easy to
get the pointers wrong. so a macro can check them now.
2012-10-10 16:59:07 +02:00
Tigran Aivazian
4705ec60ad Use the local copy of the global G_width variable. 2012-10-10 13:57:28 +01:00
Tigran Aivazian
ba84bb56d3 Use the local copy of the global G_width variable. 2012-10-10 13:55:38 +01:00
Tigran Aivazian
a68407a770 Add image info to the Menu status top bar. 2012-10-10 13:22:28 +01:00
Tigran Aivazian
13646a3d51 Support only grayscale images for now. 2012-10-10 13:15:16 +01:00
Tigran Aivazian
aa3bfb8439 Add simple scaling support. 2012-10-10 13:09:25 +01:00
Tigran Aivazian
afc89beb80 Merge branch 'djvu-crash' into picviewer 2012-10-10 11:48:17 +01:00
Tigran Aivazian
edd347eb55 Undo some of my changes to rendertext.lua
My fixes to kerning logic check in sizeUtf8Text(), renderUtf8Text() and
renderUtf8TextWidth() functions either caused or triggered a memory
corruption easily observable with DjVu files.
Undoing these changes fixes the corruption... or does it just make it
unnoticeable? Please review these changes to find out the answer.
2012-10-10 11:02:07 +01:00
Tigran Aivazian
c64da132c5 Merge pull request #387 from dpavlin/variable_link_font_size
recalculate font size for each link
2012-10-09 16:06:27 -07:00
{Qingping,Dave} Hou
f4f29bb12b Merge pull request #410 from tigran123/mode-refresh
Fix for the issue #404 no page redraw after setting mode from readers.
2012-10-09 15:29:22 -07:00
{Qingping,Dave} Hou
fd27ba693b Merge pull request #409 from tigran123/long-msg
Allow two decimal digits point for gamma/zoom
2012-10-09 15:29:01 -07:00
{Qingping,Dave} Hou
78301d98ff Merge pull request #408 from tigran123/crash-fix
Possible fix for the memory corruption issue #401
2012-10-09 15:28:15 -07:00