Author Topic: vpdf  (Read 717 times)

paolone

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #30 on: November 13, 2018, 03:49:12 PM »
On Aros 68k RNOPDF already works
I tried it. I can read text, which is properly formatted, but no image is rendered on the pages. This under AROS M68K.

paolone

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #31 on: November 13, 2018, 03:51:25 PM »
And proof the fonts work correctly (I think) now...
Very good.

I noticed we've hijacked your vpdf topic with RNOPDF things... Please excuse me.
Keep up the great work.

sabbate

  • Junior Member
  • **
  • Posts: 65
    • View Profile
Re: vpdf
« Reply #32 on: November 13, 2018, 07:24:11 PM »
I've never had problems with arospdf, maybe the interface could improve thanks anyway ;)

watto

  • Newbie
  • *
  • Posts: 11
    • View Profile
Re: vpdf
« Reply #33 on: November 13, 2018, 10:16:01 PM »
Just a quick update.

Some further issues due to MUI differences.  Trying to fix these up - if anyone has a good hack for tab buttons (MUIC_Title doesn't work) let me know.

I'm trying to get outlines working with NListtree and trying to fix up search.  In text links work (eg. contents page) but seem to be directing the thumbnails and not the main view.

Hopefully have something for the weekend so I can start work on something else :)

wawa

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #34 on: November 14, 2018, 09:47:52 PM »
@watto

do you have full access to aros svn repo to commit your changes? i think neil is in charge of privileges.

watto

  • Newbie
  • *
  • Posts: 11
    • View Profile
Re: vpdf
« Reply #35 on: November 16, 2018, 11:20:29 PM »
Not as yet wawa, I'd like to make some more progress before I organise anything.

Fixed up some weird tab behaviour (things loading in to the wrong child object).  The thumbnails and outline are now a RegisterGroup although this was probably not necessary so may be able to back that one out...  Colour weirdness is sorted (endianess issue - may be a problem on big endian now.)

Still to go:

1. Hook that populates the Outline text - still not working although the outline and tree itself does, just get garbled text.
2. Scrollbars disappearing or not appearing
3. Some weirdness with larger files and continuous layout modes and page numbers/scrollbars getting messed up
4. Search/copy paste (mainly text/charset conversion related)
5. Alternatives for close button on each tab (unsupported on AROS's MUIC_Title) and add back save option
6. General improvements, UI balancing, etc.
7. Alternative way to select document sizing mode (fit to window, page, etc. options)

It's reliably opening files, tabs are behaving properly, just a few more things not quite right

wawa

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #36 on: November 16, 2018, 11:23:59 PM »
would though be good not to hard code endiannes from the start. you certainly know, aros has macros for that.

watto

  • Newbie
  • *
  • Posts: 11
    • View Profile
Re: vpdf
« Reply #37 on: November 16, 2018, 11:46:00 PM »
Oddly enough it seems that Cairo causes it - the code has requested a Cairo surface ARGB but is storing BGRA.  WritePixelArray is expecting ARGB.  Should be able to work with it anyway of course.

I guess this isn't a problem for the existing ports on Morphos and OS4...

wawa

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #38 on: November 17, 2018, 12:20:09 AM »
we do have big endian targets also on aros: m68k (my favourite), ppc and incoming big endian arm/raspi.
you can send me a patch if you need testing on other platforms, pixel formats or endians.
« Last Edit: November 17, 2018, 12:25:08 AM by wawa »

sabbate

  • Junior Member
  • **
  • Posts: 65
    • View Profile
Re: vpdf
« Reply #39 on: November 24, 2018, 06:11:05 AM »
@watto

thank you so much

hi

Salvatore

watto

  • Newbie
  • *
  • Posts: 11
    • View Profile
Re: vpdf
« Reply #40 on: December 01, 2018, 06:03:22 PM »
Still working on this when time permits.

From the list above:
1. Outlines - sorted.
2. Scrollbars issue seems to be related to 3
3. Weirdness with larger files - this appears to be caused by MUIA_Height returning signed 16-bit values rather than proper 32-bit longs.  An overflow occurs which causes values to flip around and some incorrect pages are then displayed (because the values wrap around and the page view thinks they should be visible.)  This is only an issue on very large PDF files - I have a Korg Kronos manual PDF that triggers the issue reliably.  Would be nice if someone else who likes MUI/Zune could confirm whether what I'm seeing here is happening elsewhere.  I'm working on some code to deal with this myself and bypass MUIA_Height but it needs more work.  This also seems to be confusing scrollbars, causing them to display improperly, etc. which is to be expected I guess.
4. Search - still broken.  Copy/paste - now sorted.
5. Close Tab in the menu now.  Save has been added back to the menu also and seems to work.
6. Still need to work on UI balancing, the outline/thumbnails tab always opens at around 50% for some reason.
7. Document sizing - looking to fix this next.

Given the amount of changes and hacks I have made so far, it's probably easier for me to put the changes up on GitHub or similar for the time being as it'll take some time to add back in all the #ifdefs and refactor some of the hackier parts.  So I may do this in the short term so others can look at it and try build it, etc.

The main missing functions - the sizing toggle option and the search are things I want to fix before releasing tests.  The other issues can be worked around/avoided.  So hopefully some binaries/code soon.

sabbate

  • Junior Member
  • **
  • Posts: 65
    • View Profile
Re: vpdf
« Reply #41 on: December 01, 2018, 08:04:04 PM »
thank you watto  :)

aha

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: vpdf
« Reply #42 on: December 01, 2018, 08:17:49 PM »
Very good! Thank you, watto!  :D

wawa

  • Junior Member
  • **
  • Posts: 71
    • View Profile
Re: vpdf
« Reply #43 on: December 13, 2018, 11:51:11 AM »
@watto
if you going to commit to aros repo you might face some changes i introduced, mostly minor, casts and the like to satisfy paranoia on newer compilers such as gcc-6 as well as changes getting vpdf at least start at m68k, (probably mui/hooks related, i dont remember well, but the commit history will). please consider them and leave them intact/or merge them (if they are correct) to keep m68k and big endian as viable target.