Commit graph

58 commits

Author SHA1 Message Date
qwx 9d43029ff9 page: performance fixes
- fix showpage1 only decrementing proc counter once limit is reached;
this blocked having more than one loadpages process after NPROC calls,
since the next one has to wait until the last has exited
- allow procs to skip pages currently being loaded by others; this
forced processes to wait for each other at the same page
- bump NPROC from 4 to 8
- (hack) immediately fork a few times after adding all pages at
startup to force loading a batch of pages in parallel
2022-01-19 22:58:53 +00:00
Humm 50d23b6acc page: fix for kerTeX dvi 2021-04-09 16:40:56 +02:00
ftrvxmtrx 4c0c82d6f7 page: remove unused variables 2016-11-17 02:11:35 +01:00
cinap_lenrek 918cb76040 page: fix deadlock, nil vs 0 for pointer comparsion, cleanup 2015-07-24 11:45:48 +02:00
cinap_lenrek cbd1ca6877 page: make lookahead fetch work in backwards direction 2015-07-11 02:42:14 +02:00
cinap_lenrek e4436ec0bb page: fix deadlock with addpage (thanks BurnZeZ for the stacktraces)
addpage() should not be called with the display locked as it
calls showpage1() which sleeps when there are too many
processes active.

the bug was triggered by plumbing to trigger the addpage().
2014-07-15 20:45:00 +02:00
cinap_lenrek 0181117b5f fork filter procs with RFREND in various programs 2014-02-21 05:32:20 +01:00
cinap_lenrek 14770ad188 page: fix compiler warning 2014-02-14 15:01:14 +01:00
cinap_lenrek 59d8c24f58 page: fix page bookmarks for epub files 2013-12-28 06:49:51 +01:00
cinap_lenrek 1059da0066 page: scrollwheel, better backwards scrolling, fix blit bug when page was translated offscreen 2013-12-23 15:38:52 +01:00
cinap_lenrek 48d2f14f80 page: implement bookmarks (thanks trav_ for starting it)
add new functions pageaddr() that returns a string describing
the page to be loaded. it is in the form of:

/path/to/file!pagename!subpage!....

one can jump to such a page by calling trywalk(name, addr)
where name and addr get concatinated with ! to form a page
address and then the currently loaded pages are walked up
to the nearest page which is then returned. (or nil when
not found). the remaining address will be set in the global
pagewalk variable.

once pages get loaded (asynchronously), pagewalk1() gets
called again on addpage() and continues the walking up to the
last page.

new program flag -j <addr> was added to jump to a page on
startup.

page address (without filename) can also be supplied in
plumb message with the "addr" attribute.
2013-12-21 18:04:14 +01:00
cinap_lenrek 0b42409cf4 page: avoid intermediate rc shell processes with using exec, move newwindow() before forking namespace
use exec to avoid intermediate rc processes.

avoid capturing old namespace in the waiting process by doing the
newwindow() call before it.
2013-10-04 21:10:33 +02:00
cinap_lenrek 8c1d4604db page: close stdout, reopen stdout/stderr for external viewer and removed useless RFNAMEG flag
we are not using stdout (fd=1) and it, so dup nullfd over it.
this drops the old window reference when using with -w flag.

the RFNAMEG flag isnt needed because we are calling newwindow()
which forks the namespace for us.

reopen stdin/stdout for the external viewer to the new window.
2013-10-04 16:03:41 +02:00
cinap_lenrek 5c4756974b page: dont tell rio our pid
$wsys might be from a remote system so pid will not work.

new rio errors out on mouse/cons instead.
2013-10-04 02:26:40 +02:00
cinap_lenrek 631ac3d2e2 page: maintain a lru list and do unloading from oldest to newest 2013-08-03 17:37:20 +02:00
cinap_lenrek 041eb4b30d page: use less aggressive read ahead and keep track of image memory allocation 2013-08-03 04:11:24 +02:00
cinap_lenrek 41c306dfda page: handle combination or -w and -R flags (thanks BurnZeZ) 2013-07-08 20:50:39 +02:00
ppatience0 043c8e4453 tif: add tiff decoder 2013-07-02 01:57:14 -04:00
cinap_lenrek 9369f83bcd page: use resizewin() to change window size for gif display
resizewin() has some extra logic making sure the rect doesnt get too big.
rio would otherwise refuse to create the window and the operation will fail
completely.
2013-06-17 08:05:04 +02:00
cinap_lenrek 3d581e8b72 page: 12 zoom levels should be enougth
making zoom too big just causes pagesize() multiplication to overflow
passing bogus rectangles to allocimage().
2013-06-15 21:09:27 +02:00
cinap_lenrek 686f9fa1db page: handle interrupt note 2013-06-09 01:51:19 +02:00
cinap_lenrek c9e79c27a6 page: exit on kill note 2013-06-09 01:36:45 +02:00
cinap_lenrek e18b9f6fd2 tga: fix bad output channel descriptor for grayscale images and -9 flag, revert page work arround 2013-01-21 11:09:47 +01:00
ftrvxmtrx 44b337fbdb page: image/tga 2013-01-21 00:07:05 +01:00
ftrvxmtrx 7addee38a9 page: force images to RGB using -3 flag (fixes grey-scale images displaying) 2013-01-21 00:06:36 +01:00
cinap_lenrek 2a9b90cf85 page: fix drawpage race 2012-08-12 20:25:22 +02:00
cinap_lenrek abba8aa7a9 page: simplify locking, avoid eenter deadlock on resize 2012-08-09 04:03:03 +02:00
cinap_lenrek 0989c2530d microsoft ico format conversion support 2012-04-01 04:57:11 +02:00
cinap_lenrek 3a83a68e0b page: allow running external jpg(1) program for animated gifs, mothra: handle gif with page 2012-03-10 06:55:54 +01:00
cinap_lenrek 96857088f4 page: improve shortname() 2012-02-20 10:49:54 +01:00
cinap_lenrek 9582ef60df page: can't just cover whole display 2012-02-09 06:14:36 +01:00
cinap_lenrek 95e15c3e1d page: don't resize window bigger than the dislay 2012-02-09 05:20:25 +01:00
cinap_lenrek 27830ae53e page: refactor menu 2011-12-21 21:19:37 +01:00
cinap_lenrek 1d83d2a74e page, mothra: corral rogue note groups 2011-12-21 07:45:30 +01:00
cinap_lenrek 4dd4213677 handle initdraw errors 2011-12-10 23:01:15 +01:00
cinap_lenrek 9b6ecc6114 page: fix noseek detection for files like /dev/screen 2011-11-29 13:42:15 -05:00
cinap_lenrek 0f382bbf92 page: add write command to save current page as compressed plan9 bitmap 2011-10-31 19:43:05 +01:00
cinap_lenrek c50bef06dd can't use rfork without RFMEM from shared memory procs and then use heap as it might be cow in a inconsistent state 2011-10-24 17:10:44 +02:00
cinap_lenrek e2ed2a0b7e page: nested browsing 2011-10-18 10:02:06 +02:00
cinap_lenrek b318debfc2 page: avoid drawing background if image has no alpha channel 2011-10-18 03:41:57 +02:00
cinap_lenrek 681363caae page: print readimage error string 2011-10-12 06:38:11 +02:00
cinap_lenrek 79589ef3fb page: fix filedescriptor leakage 2011-10-11 08:19:32 +02:00
cinap_lenrek 00f9b5d7f1 page: properly draw images with alpha channel, cleanup 2011-10-11 05:34:14 +02:00
cinap_lenrek 19d3840701 page: refactor code, skip dummy pages, faster zoomdraw 2011-10-10 05:13:33 +02:00
cinap_lenrek 6f5e6eff59 page: fix draw performance problem on t23 2011-10-05 02:18:23 +02:00
cinap_lenrek 569e0181b2 mothra: animated gifs, page: cleanup 2011-10-05 00:05:51 +02:00
cinap_lenrek 3efbb4fa00 use file(1) in page and mothra to detect file type 2011-10-04 18:48:31 +02:00
cinap_lenrek b87828cf43 page: use param f instead of global zoom 2011-10-02 15:05:01 +02:00
cinap_lenrek 94646a4287 html2ms: table support 2011-09-21 14:17:27 +02:00
cinap_lenrek 6c91d99ce2 uhtml: remove trailing utf BOM marker, html2ms: fix underline handling and escaping 2011-09-20 04:14:29 +02:00