• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Safari scroll bar problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Safari scroll bar problem


  • Subject: Re: Safari scroll bar problem
  • From: Brian Christmas <email@hidden>
  • Date: Thu, 01 Sep 2016 21:24:14 +1000

G’day scripters

Thanks Shane, I’ll look at that.

Phil, it’s not important that I determine the scroll position accurately, which does fluctuate as the site being displayed loads more pages, but I merely need to know if the scroll position is 0.0, 1.0 (or greater, so finished), or in-between.

Unfortunately, as Bill pointed out, Safari is unreliable in determining scroll position. I’ve found between Safari starts, it seems to vary in it’s responses, and also acts up on certain sites, and not others.

It’s a bit of a bummer, but not important. My App still does what it was intended to do, freeze my iMac! Just thought others might like to know of the problem, and check for remedies.

Also, does anyone else suffer from the freezing iMac syndrome? I have a 4GB graphics card, and am wondering if it’s the problem. OR, my 32GB third party RAM (Crucial brand).

Regards

Santa


On 1 Sep 2016, at 4:16 PM, Phil Stokes <email@hidden> wrote:

I understand the need to scroll programmatically - I meant I don’t understand the need to locate the scroll bar element in the UI, which will change depending on the window’s bounds and thus be unreliable for coding.

In AppKit framework, NSResponder has scrollToBeginningOfDocument and scrollToEndOfDocument methods, which you could try implementing in ASObjC. I suspect you’d first have to get a reference to the Window’s text or webkit view to call it.

Another way to scroll up and down entirely might be just to get each page’s contents, and try to alternately set the insertion point or location at the beginning or end of the range.

I’m not at a computer I can play with code at the moment, but I’ll have a mess about with these a bit later to see if I can come up with some concrete code examples.


Best


P

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Safari scroll bar problem
      • From: 2551phil <email@hidden>
  • Prev by Date: Re: Safari scroll bar problem
  • Next by Date: Re: Safari scroll bar problem
  • Previous by thread: Re: Safari scroll bar problem
  • Next by thread: Re: Safari scroll bar problem
  • Index(es):
    • Date
    • Thread