• 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: NSRulerView flexibility
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSRulerView flexibility


  • Subject: Re: NSRulerView flexibility
  • From: "Steve Shepard" <email@hidden>
  • Date: Sun, 21 Oct 2007 09:49:20 -0700

It is possible to do what you are asking (see the rulers in Storyist),
but there is some work involved. The class to subclass is NSRulerView
and you'll do most of your custom drawing in
drawHashMarksAndLabelsInRect:

I had to override some private methods to get this to draw without
artifacts when scrolled.

-Steve
www.storyist.com

On 10/17/07, David Harper <email@hidden> wrote:
> hi,
>
> Is it possible to
>
> (a) have multiple zero points for vertical ruler views within a scroll view?
> ---
> My application has multiple pages that accumulate vertically in an extending scroll view.  I'd like to have the top of each page correspond to a zero on the vertical ruler view, or start new ruler views at the top of each page.
>
> (b) end horizontal ruler views?
> ---
> I'd like the horizontal rules to end at the right side of the page.  That is, go from 0 to 8.5" for a standard letter page instead of stretching as wide as the user decides to make the window.
>
> I have a feeling I'm going to have to make a subclass of a generic NSView to accomplish this.  If there are any other options I'd appreciate your input.
>
>
> Thanks again,
> -Dave H.
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >NSRulerView flexibility (From: David Harper <email@hidden>)

  • Prev by Date: Re: Best working hours model to use with Bindings
  • Next by Date: Re: Question Mark Cursor
  • Previous by thread: NSRulerView flexibility
  • Next by thread: Re: NSRulerView flexibility
  • Index(es):
    • Date
    • Thread