llpp/slowscroll.git
5 years agoPhy. vs Str. equality strikes againfractional
malc [Tue, 30 Aug 2016 17:37:52 +0000 (30 20:37 +0300)]
Phy. vs Str. equality strikes again

5 years agoReal coordinatesfrational
malc [Tue, 30 Aug 2016 16:28:44 +0000 (30 19:28 +0300)]
Real coordinates

Addresses https://github.com/moosotc/llpp/issues/34 also too ugly to live

5 years agoRemove redundant entry
malc [Mon, 29 Aug 2016 21:23:34 +0000 (30 00:23 +0300)]
Remove redundant entry

5 years agoFix visibility conditions
malc [Mon, 29 Aug 2016 21:06:08 +0000 (30 00:06 +0300)]
Fix visibility conditions

5 years agoTypes...
malc [Sun, 28 Aug 2016 15:59:14 +0000 (28 18:59 +0300)]
Types...

5 years agoUhm... shell is hard too
malc [Sun, 28 Aug 2016 15:28:56 +0000 (28 18:28 +0300)]
Uhm... shell is hard too

5 years agoFix vertical bar scrolling when maxfit is false
malc [Fri, 26 Aug 2016 15:06:43 +0000 (26 18:06 +0300)]
Fix vertical bar scrolling when maxfit is false

5 years agoSmart(er) mouse wheel zooming
malc [Fri, 26 Aug 2016 00:05:11 +0000 (26 03:05 +0300)]
Smart(er) mouse wheel zooming

Maybe some day should be enabled as a config option.

5 years agoStop gap listview scrollbars solution
malc [Thu, 25 Aug 2016 23:16:15 +0000 (26 02:16 +0300)]
Stop gap listview scrollbars solution

5 years agoFix horizontal scrollbar
malc [Thu, 25 Aug 2016 22:24:56 +0000 (26 01:24 +0300)]
Fix horizontal scrollbar

5 years agoHide veritcal scroll bar when not needed
malc [Thu, 25 Aug 2016 21:59:04 +0000 (26 00:59 +0300)]
Hide veritcal scroll bar when not needed

If the document fits the window vertically. This also matches
horizontal behavior.

5 years agoBegin scrollbar overhaul
malc [Thu, 25 Aug 2016 21:55:04 +0000 (26 00:55 +0300)]
Begin scrollbar overhaul

This is "wrong", but the old approach was very ad hoc and caused major
pains.

Random points:

a. Behavior with this patch lends itself to an en vogue way of fading
   out bars

b. Scrollbars are hard - https://bugzilla.mozilla.org/show_bug.cgi?id=1248118

c. Perhaps view and bar areas should be covered by different view
   ports. This would be the "right" thing to do, but will probably
   require substantial changes all over the place

5 years agoUse centered zooming pervasively
malc [Thu, 25 Aug 2016 16:23:37 +0000 (25 19:23 +0300)]
Use centered zooming pervasively

5 years agoFix visible area calculation
malc [Thu, 25 Aug 2016 16:06:41 +0000 (25 19:06 +0300)]
Fix visible area calculation

5 years agoBe greedy
malc [Thu, 25 Aug 2016 14:25:34 +0000 (25 17:25 +0300)]
Be greedy

5 years agoAddress #33
malc [Thu, 25 Aug 2016 14:17:46 +0000 (25 17:17 +0300)]
Address #33

Takeaways:
a. scrollbars ought to be re-engineered
b. scrollbar doesn't end with an 'e'

5 years agoFix selection zooming
malc [Thu, 25 Aug 2016 01:28:03 +0000 (25 04:28 +0300)]
Fix selection zooming

5 years agoFix placement of list view selection rectangle
malc [Thu, 25 Aug 2016 01:05:57 +0000 (25 04:05 +0300)]
Fix placement of list view selection rectangle

5 years agoPrevent scroll bar width double accounting
malc [Thu, 25 Aug 2016 00:35:11 +0000 (25 03:35 +0300)]
Prevent scroll bar width double accounting

5 years agoDo not pivotzoom when there are pending geometry changes
malc [Wed, 24 Aug 2016 10:11:09 +0000 (24 13:11 +0300)]
Do not pivotzoom when there are pending geometry changes

This is a sledgehammer approach but nothing better springs to mind at
the moment.

5 years agoFix vertical positioning with pivot zooming
malc [Wed, 24 Aug 2016 01:00:49 +0000 (24 04:00 +0300)]
Fix vertical positioning with pivot zooming

Wrong calculations inside represent went unnoticed for far too long
due to the fact that by default window dimensions are the same
(900x900).

5 years agoFix rect zooming
malc [Tue, 23 Aug 2016 21:24:14 +0000 (24 00:24 +0300)]
Fix rect zooming

And probably a lot more.

5 years agoZoom centering
malc [Tue, 23 Aug 2016 21:15:18 +0000 (24 00:15 +0300)]
Zoom centering

Needs more work for (at least) mouse wheel I suppose.

5 years agoSimplify
malc [Sat, 20 Aug 2016 23:42:00 +0000 (21 02:42 +0300)]
Simplify

5 years agoUse correct x coordinate when layouting
malc [Thu, 18 Aug 2016 23:02:47 +0000 (19 02:02 +0300)]
Use correct x coordinate when layouting

Sigh...

5 years agoUse hypot instead of open coding it
malc [Thu, 18 Aug 2016 19:10:53 +0000 (18 22:10 +0300)]
Use hypot instead of open coding it

Given that other C99 features crept in anyways.

5 years agoCosmetics
malc [Sun, 7 Aug 2016 00:06:25 +0000 (7 03:06 +0300)]
Cosmetics

5 years agoMorf gotoy into gotoxy
malc [Sat, 30 Jul 2016 17:06:21 +0000 (30 20:06 +0300)]
Morf gotoy into gotoxy

When old code needed to adjust horizontal position it just merrily set
the state.x to the needed value and called gotoy, that was wrong in
case of throttling - gotoy might fail, so that state.y wasn't updated
but state.x was uncodnitionally set and the result was in inconsistent
behavior - one could end up in a situation where some tiles were
rendered - immediately evicted from the cache and then scheduled to be
rendered again.

5 years agoSuppress redisplay on invalidation
malc [Thu, 28 Jul 2016 01:39:23 +0000 (28 04:39 +0300)]
Suppress redisplay on invalidation

We can end up in a situation when throttling is active, redisplay is
scheduled (if post-processing fails) and then invalidate is called -
resulting in an empty layout and consequently flickering.

This is probably the third time when post-processing intricacies
lead to nasty visual issues.

Reproducer:

mkfifo /tmp/fifo
llpp some.pdf -remote /tmp/fifo &
echo 'keys ctrl-0' >/tmp/fifo
for i in $(seq 1 100); do
    echo 'keys ctrl-+' >/tmp/fifo;
    sleep 0.01;
done;

5 years agoCosmetics
malc [Tue, 26 Jul 2016 22:25:18 +0000 (27 01:25 +0300)]
Cosmetics

5 years agoFix logcurrently (angle was forgotten)
malc [Tue, 26 Jul 2016 21:48:30 +0000 (27 00:48 +0300)]
Fix logcurrently (angle was forgotten)

6 years agoJust lock, do not warn buyers
malc [Fri, 15 Jul 2016 09:58:00 +0000 (15 12:58 +0300)]
Just lock, do not warn buyers

6 years agoDrop timed lock inside post-processing
malc [Thu, 14 Jul 2016 20:21:59 +0000 (14 23:21 +0300)]
Drop timed lock inside post-processing

This introduced nasty usability regression - any failure to take the
lock during post-processing results in a "freeze" so to speak. Hence
indicate the failure due to magical -1 post-processing return code and
schedule re-display if seen from the OCaml side, meaning the display
and post-processing will be triggered on any future event (most likely
the notification from the rendering/loading side that will likely
release the lock and allow forward progress)

Things work fine with original offender (visualFAQ.pdf -
http://tug.ctan.org/info/visualFAQ/visualFAQ.pdf) as does scrolling
around (mainly horizontally) in sufficiently large and zoomed in
image, such as:
https://upload.wikimedia.org/wikipedia/commons/c/c4/Vasily_Surikov_-_%D0%91%D0%BE%D1%8F%D1%80%D1%8B%D0%BD%D1%8F_%D0%9C%D0%BE%D1%80%D0%BE%D0%B7%D0%BE%D0%B2%D0%B0_-_Google_Art_Project.jpg)

6 years agoRobustify
malc [Thu, 14 Jul 2016 12:57:06 +0000 (14 15:57 +0300)]
Robustify

6 years agoSync with upstream
malc [Thu, 14 Jul 2016 02:01:12 +0000 (14 05:01 +0300)]
Sync with upstream

6 years agoGive ml_postprocess a chance to succeed
malc [Tue, 12 Jul 2016 23:58:42 +0000 (13 02:58 +0300)]
Give ml_postprocess a chance to succeed

Admittedly this is fugly, but no clean solution immediately springs to
mind.

(Register continuation that will be called upon unlock and will notify
caml code to retry? Use cloned contexts? Something else?)

All other trylocks are just as ugly, but probably much less noticeable.

6 years agoFix locking
malc [Tue, 12 Jul 2016 22:30:33 +0000 (13 01:30 +0300)]
Fix locking

6 years agoAdd clang guard
malc [Tue, 12 Jul 2016 21:46:16 +0000 (13 00:46 +0300)]
Add clang guard

6 years agoUpdate ignore list
malc [Tue, 12 Jul 2016 17:26:58 +0000 (12 20:26 +0300)]
Update ignore list

Tramp auxiliary files.

6 years agoSync with upstream
malc [Tue, 12 Jul 2016 17:26:20 +0000 (12 20:26 +0300)]
Sync with upstream

Also fix some issues reported by valgrind.

6 years agoRevert a bunch of syncs
malc [Tue, 12 Jul 2016 11:44:22 +0000 (12 14:44 +0300)]
Revert a bunch of syncs

Things are rather sad. Segfaults, compilation problems, etc, on top of
that Tor is on vaccation. So let's take it slow and stick to a
slightly outdated mupdf, but at least it works (that's not to say that
those are mupdf problems)

6 years agoSafety net
malc [Tue, 12 Jul 2016 11:11:54 +0000 (12 14:11 +0300)]
Safety net

null pointer dereference with "Frank Frazetta - Fantasy Illustrated #2.pdf"

6 years ago"Fix" trimctm
malc [Tue, 12 Jul 2016 10:39:23 +0000 (12 13:39 +0300)]
"Fix" trimctm

I don't have any idea what's going on here. Details:

mupdf 834243dbfc8ab3e9269b7a789d61e3fe0f8e71f7 - good
      e2a85460370a3110b89fb838bc924c73f87f5b3c - bad

Most things work with either of those, except for:
http://www.gly.uga.edu/railsback/11111misc/SizeofThings36.pdf

6 years agoSync with upstream
malc [Sat, 9 Jul 2016 15:08:14 +0000 (9 18:08 +0300)]
Sync with upstream

6 years agoSync with upstream
malc [Fri, 8 Jul 2016 20:32:08 +0000 (8 23:32 +0300)]
Sync with upstream

6 years agoRefactor
malc [Wed, 6 Jul 2016 18:15:19 +0000 (6 21:15 +0300)]
Refactor

rotate is initialized the same way in both branches, so initialize it
once.

6 years agoSync with upstream
malc [Wed, 6 Jul 2016 17:50:36 +0000 (6 20:50 +0300)]
Sync with upstream

The trimctm stuff and the whole poling deep into fitz internals is
pretty fragile and disgusting, maybe this should be revisited.

Raison d'ĂȘtre for some of those "optimizations" was speed,
DDI0406B_arm_architecture_reference_manual_errata_markup_8_0.pdf
and
ECMA-376, Second Edition, Part 1 - Fundamentals And Markup Language Reference.pdf

[maybe things aren't as atrocious now (speed wise) as they were when some
 of those "hacks" were introduced]

6 years agoConsistency
malc [Sat, 2 Jul 2016 19:45:25 +0000 (2 22:45 +0300)]
Consistency

6 years agoCosmetics
malc [Sat, 2 Jul 2016 19:42:31 +0000 (2 22:42 +0300)]
Cosmetics

6 years agoAbstract keyboard handling a bit more
malc [Wed, 29 Jun 2016 11:29:17 +0000 (29 14:29 +0300)]
Abstract keyboard handling a bit more

6 years agoCosmetics
malc [Wed, 29 Jun 2016 09:37:38 +0000 (29 12:37 +0300)]
Cosmetics

6 years agoKill stray space
malc [Sat, 25 Jun 2016 17:50:02 +0000 (25 20:50 +0300)]
Kill stray space

6 years agoChange splitatspace to return a pair
malc [Sat, 25 Jun 2016 17:46:48 +0000 (25 20:46 +0300)]
Change splitatspace to return a pair

6 years agoSimplify
malc [Sat, 25 Jun 2016 12:54:06 +0000 (25 15:54 +0300)]
Simplify

6 years agoAdd remote `keys' command
malc [Fri, 24 Jun 2016 19:34:01 +0000 (24 22:34 +0300)]
Add remote `keys' command

6 years agoRemove diagnostic pragmas around fitz/mupdf headers
malc [Fri, 24 Jun 2016 13:18:07 +0000 (24 16:18 +0300)]
Remove diagnostic pragmas around fitz/mupdf headers

Apparently the issues with warnings were fixed upstream.

6 years agoDemacrofication
malc [Thu, 23 Jun 2016 09:21:58 +0000 (23 12:21 +0300)]
Demacrofication

Replace MIN/MAX usage with calls to fz_min/max[i].

6 years agoSync with upstream
malc [Thu, 23 Jun 2016 08:20:29 +0000 (23 11:20 +0300)]
Sync with upstream

6 years agoFix typo
malc [Wed, 22 Jun 2016 15:17:19 +0000 (22 18:17 +0300)]
Fix typo

Right... Coud those sort of typos thinkos be avoided? No idea...

6 years agoSync with upstream
malc [Sat, 18 Jun 2016 09:20:43 +0000 (18 12:20 +0300)]
Sync with upstream

6 years agoCosmetics
malc [Fri, 10 Jun 2016 17:33:41 +0000 (10 20:33 +0300)]
Cosmetics

We only need to build libs part of mupdf.

6 years agoRefactor
malc [Mon, 30 May 2016 21:34:04 +0000 (31 00:34 +0300)]
Refactor

6 years agoFix native builds
malc [Mon, 30 May 2016 21:15:12 +0000 (31 00:15 +0300)]
Fix native builds

Thanks to Tuncer Ayaz for heads up. (Also this can use some refactoring).

6 years agoMake hlint happy
malc [Thu, 26 May 2016 11:06:32 +0000 (26 14:06 +0300)]
Make hlint happy

6 years agoDedup
malc [Wed, 25 May 2016 21:06:16 +0000 (26 00:06 +0300)]
Dedup

6 years agoCosmetics
malc [Wed, 25 May 2016 11:30:17 +0000 (25 14:30 +0300)]
Cosmetics

Coincidentally fixes dyslexia.

6 years agoAdd fb2
malc [Tue, 24 May 2016 22:09:26 +0000 (25 01:09 +0300)]
Add fb2

6 years agoQuoting
malc [Tue, 24 May 2016 18:04:23 +0000 (24 21:04 +0300)]
Quoting

Strangely enough this works better.

6 years agoSync with upstream
malc [Tue, 24 May 2016 15:28:38 +0000 (24 18:28 +0300)]
Sync with upstream

6 years agoMore dedup
malc [Tue, 24 May 2016 11:59:01 +0000 (24 14:59 +0300)]
More dedup

6 years agoAvid duplication
malc [Tue, 24 May 2016 11:49:26 +0000 (24 14:49 +0300)]
Avid duplication

6 years agoMerge branch 'ghennequin-master'
malc [Tue, 24 May 2016 11:39:28 +0000 (24 14:39 +0300)]
Merge branch 'ghennequin-master'

6 years agoMerge branch 'master' of https://github.com/ghennequin/llpp into ghennequin-masterghennequin-master
malc [Tue, 24 May 2016 11:38:41 +0000 (24 14:38 +0300)]
Merge branch 'master' of https://github.com/ghennequin/llpp into ghennequin-master

6 years agoAdded more precise building instructions for mupdf in [BUILDING]
Guillaume Hennequin [Tue, 24 May 2016 10:57:53 +0000 (24 11:57 +0100)]
Added more precise building instructions for mupdf in [BUILDING]

6 years agoTrim more stray whitespace
malc [Sat, 14 May 2016 20:29:33 +0000 (14 23:29 +0300)]
Trim more stray whitespace

6 years agoKill stray space
malc [Sat, 14 May 2016 20:20:49 +0000 (14 23:20 +0300)]
Kill stray space

6 years agoAdd fz_var annotations where appropriate
malc [Sat, 7 May 2016 18:41:44 +0000 (7 21:41 +0300)]
Add fz_var annotations where appropriate

Thanks to Tuncer Ayaz for heads up.

Worth metnioning that the warnings only trigger when source is
compiled with optimizations (those were set to 0 (i.e. -O0) over here
so were absent when the source was compiled locally)

6 years agoUse proper matrix
malc [Tue, 3 May 2016 14:27:26 +0000 (3 17:27 +0300)]
Use proper matrix

Takes trimming into account among other things.

6 years agoRemove pointless code
malc [Tue, 3 May 2016 14:13:35 +0000 (3 17:13 +0300)]
Remove pointless code

6 years agoFix hovering over final char in a region of interest
malc [Tue, 3 May 2016 13:29:00 +0000 (3 16:29 +0300)]
Fix hovering over final char in a region of interest

Thanks for heads up to Tor Andersson.

6 years agoAdd svg
malc [Tue, 3 May 2016 12:04:20 +0000 (3 15:04 +0300)]
Add svg

6 years agoCompress more
malc [Fri, 29 Apr 2016 02:39:10 +0000 (29 05:39 +0300)]
Compress more

6 years agoCompress
malc [Fri, 29 Apr 2016 02:36:49 +0000 (29 05:36 +0300)]
Compress

6 years agoMerge branch 'tuncer-mupdf-release-native'
malc [Thu, 28 Apr 2016 18:42:48 +0000 (28 21:42 +0300)]
Merge branch 'tuncer-mupdf-release-native'

6 years agoAdd target build/llpp.murel.nativetuncer-mupdf-release-native
Tuncer Ayaz [Thu, 28 Apr 2016 18:26:11 +0000 (28 20:26 +0200)]
Add target build/llpp.murel.native

This expects a mupdf tree that's been built in release mode and is
needed because -march=native objects can use instructions that are not
supported by all CPUs.

6 years agoSilence the compiler
malc [Wed, 27 Apr 2016 22:37:47 +0000 (28 01:37 +0300)]
Silence the compiler

w.r.t. lablGL

6 years agoCosmetics
malc [Sat, 2 Apr 2016 22:47:48 +0000 (3 01:47 +0300)]
Cosmetics

6 years agoRoll own ASCII lowercase functionality
malc [Fri, 1 Apr 2016 19:14:55 +0000 (1 22:14 +0300)]
Roll own ASCII lowercase functionality

4.03 deprecates lowercase functions, and lowercase_ascii is not
available on prior compilers, roll our own.

cf. https://sympa.inria.fr/sympa/arc/caml-list/2016-04/msg00005.html

6 years agoCollapse extended parameters before exiting
malc [Mon, 28 Mar 2016 13:47:03 +0000 (28 16:47 +0300)]
Collapse extended parameters before exiting

Something has to be done with this mess.

6 years agoWikipedia mode
malc [Mon, 28 Mar 2016 09:54:13 +0000 (28 12:54 +0300)]
Wikipedia mode

6 years agomupdf can handle bmps on its own now
malc [Thu, 24 Mar 2016 20:42:27 +0000 (24 23:42 +0300)]
mupdf can handle bmps on its own now

6 years agoSync with upstream
malc [Thu, 24 Mar 2016 18:18:17 +0000 (24 21:18 +0300)]
Sync with upstream

6 years agoMerge pull request #14 from nojb/fix-osx-x11-socket-name
moosotc [Sun, 20 Mar 2016 09:27:52 +0000 (20 13:27 +0400)]
Merge pull request #14 from nojb/fix-osx-x11-socket-name

OS X: recognize X11 unix socket path in $DISPLAY

6 years agoIndentation
malc [Mon, 14 Mar 2016 21:49:03 +0000 (15 00:49 +0300)]
Indentation

6 years agoSync with upstream
malc [Mon, 14 Mar 2016 17:45:38 +0000 (14 20:45 +0300)]
Sync with upstream

6 years agoShrug
malc [Mon, 14 Mar 2016 13:47:21 +0000 (14 16:47 +0300)]
Shrug

6 years agoAllow specifying output path name via command line
malc [Mon, 29 Feb 2016 23:11:53 +0000 (1 02:11 +0300)]
Allow specifying output path name via command line

6 years agoUse command line instead of clipboard to specify urls
malc [Mon, 29 Feb 2016 06:19:16 +0000 (29 09:19 +0300)]
Use command line instead of clipboard to specify urls

6 years agoEnable css hack for shake builds
malc [Mon, 29 Feb 2016 06:17:16 +0000 (29 09:17 +0300)]
Enable css hack for shake builds

6 years agoUpdate
malc [Mon, 29 Feb 2016 06:16:32 +0000 (29 09:16 +0300)]
Update