PDA

View Full Version : Ands-PDF - PDF Viewer for DS v1.4



wraggster
March 17th, 2009, 23:57
Albinofrenchy (http://forum.gbadev.org/viewtopic.php?t=16468) has posted a new release of his pdf viewer for the DS:


Sorry for the delay to v1.4; but to make up for it, I've included a lot of new features!

Binary (Note: You must put the fonts folder at the root level of your slot-1 device)
Source

Changelog from 1.3 to 1.4:

Features:

New viewing mode. This is the 'reader' mode. More on that later.
D-pad now pans the screen. I got alot of requests for this one!

File browser is now filtered; will only show PDF files. Note that it will show folders that don't have PDF files in them.

You can now adjust the backlit brightness by holding down Select + Up/Down arrows.

You can now cancel out of the file browser with 'B', or by clicking the file browser button again.
Rendering is getting progressively faster.

Mini-help screen and info screen on startup.
Added splash screen. If you find this annoying, remove the splash files in the FONTS folder, and it will bypass this step.

Fonts are external now. This gives us alot more memory to play with at the expense of higher load times on certain PDF's. (Note: I took out the dingbats font. If anyone as a PDF that has dingbats, I will hand out that file too... It is much larger though).

Bug Fixes:

You can no longer scroll off the bottom of the file browser.
Some memory issues resolved that led to instability.
The zoom-tool used to mess up if you clicked it more than once. Doesn't anymore.
Tons of other stuff I'm sure...
Reader Mode

There is a new icon on the tool bar that looks like a paper with a lower case 'r' on it. This button brings you to the reader mode.

The reader mode serves two purposes. First, it lets you quickly navigate through pages. Second, it lets you read the text of a PDF in a format appropriate for the NDS.

I'm really excited about this new feature, however it isn't as far along as I would hope. The long and short of it is that the way PDF files store their text is difficult to read since every PDF generator seems to do it a bit differently; and there are a number of different font formats as well. This effectively means that it won't work for all PDF's, and won't do what you expect it to do for many more. I considered not releasing until I had everything working, but figured people would want new features even if some of them were faulty.

Some PDF's will render fine in the text view. Some will render with no spaces. Others will not render at all (I haven't run into alot of those, but, unfortunately, I suspect that non-latin encodings suffer much more greatly from this.) I haven't completely nailed down the auto-formating, but I'm close. You'll probably notice some puncutation is goofed up; thats another thing I'm working on. Its a work in progress.

If you have a document that doesn't look right in the reader mode that you don't mind sharing, please please contact me either here or elsewhere. I probably won't be able to respond to everyone, but I will look at it, and will try to figure out how to make it work right. Thank you!

To the right is a typical screen shot of the reader mode. On the bottom screen are different page layouts. On the top screen is the text pulled from the page. You can scroll the text via the D-Pad up and down keys, and change pages by the right and left keys. Touching pages will also give them focus. The numbers are, intuitively enough, the page numbers for that page.

Controls
General:

Start opens a new file ('B' will cancel this operation.)
Select + Up/Down adjusts the screen brightness to the desired level
B button toggles view mode between normal document view mode and reader view mode.
Normal Viewer Mode:

D-Pad pans the document
X toggles between book mode and normal mode
Right Shoulder/A moves forward a page.
Left Shoulder/Y moves back a page.
Reader Mode:

Right/Left arrow moves page forward/backward
Up/Down arrow moves page text up or down.
Installation Notes

Unlike the previous versions, this one has font artifacts you need to keep on the flashdrive for some PDF's to load correctly. You must put the FONTS folder on your card at the root level. To do this you can simply unzip the contents of the binary zip file on to your slot-1 device. This will put the FONTS folder and the nds file on the device. You can move the nds file wherever you want, but you cannot move the fonts folder. I hope to make this configurable in the future, but we aren't there yet.

As always, please post any comments, questions, bug reports, etc etc :)

Download and Give Feedback Via Comments

crookedmouth
March 19th, 2009, 04:47
I still cannot get this to display anything more then the title page of some PDFs with most resulting in error.

Does anyone know of something I could try that works.

This is a great project and I hope it continues.