Page 1 of 1

RevBrowser unable to control the scroll

Posted: Thu Dec 12, 2019 11:07 am
by Simon Knight
Hi,
I have a utility application (code for never finished!) that displays pdf scans of A4 sized documents in a revbrowser on a stack. The revbrowser is positioned using an image control that occupies the lefthand side of the stack. The application allows the user to resize the stack to fit on various screen sizes and one handler controls the layout of the controls. The browser is set to display scroll bars so that multi page scans may be viewed.

The application is working but I have noticed a problem : as the stack width is increased so is the width of the browser and above a certain width the pdfs are displayed partially scrolled down. The exact width that this occurs depends on the height of the browser and is most likely to do with the ratio of height to width of the A4 sized pdf scans. Its possible to scroll up using the scroll bar but setting the vscroll property has no effect.

Code: Select all

on setvScroll
   revBrowserSet sBrowserID, "vscroll", 0
   Beep
end setvScroll
From the dictionary :
"vscroll" -The number of pixels down that the browser is scrolled. The default is zero.
I have tried a range of scroll values and the browser fails to scroll. I have also waited for the browser redraw to complete but the code still fails.

So any ideas on how I might get my browser to scroll. Also is there any way to control how the browser scales a pdf for display?

best wishes
Simon

Re: RevBrowser unable to control the scroll

Posted: Thu Dec 12, 2019 11:29 am
by Klaus
Hi Simon,

this is a bug unfortunately! :?
https://quality.livecode.com/show_bug.cgi?id=19453

But we have Hermann and his JavaScript solutions, check this:
viewtopic.php?p=156701#p156701
:D


Best

Klaus

Re: RevBrowser unable to control the scroll

Posted: Thu Dec 12, 2019 3:00 pm
by Simon Knight
Hi Klaus,

Thanks for the info. I believe that the bug report is about the widget so I have added one about the revBrowser,

best wishes

Simon

Re: RevBrowser unable to control the scroll

Posted: Thu Dec 12, 2019 3:05 pm
by Klaus
Ah, yes, always forget that there is still REVBROWSER_XXXX stuff. :D

Maybe that will be replaced completely by the widget in the future...

Re: RevBrowser unable to control the scroll

Posted: Thu Dec 12, 2019 3:18 pm
by Simon Knight
I did check that its not been marked as depreciated but it still seems valid. I have looked at the widget in the past but found that it suffered from errr bugs....

best wishes

Simon

Re: RevBrowser unable to control the scroll

Posted: Mon Dec 16, 2019 7:29 pm
by Simon Knight
Hi,

The failure to scroll the RevBrowser has been confirmed as a bug : https://quality.livecode.com/show_bug.cgi?id=22491

best wishes

Simon