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

Re: Revolving scoreboard


  • Subject: Re: Revolving scoreboard
  • From: PCWiz <email@hidden>
  • Date: Sun, 3 Jan 2010 16:27:13 -0700

This isn't something thats extremely difficult to do. You will need to create NSView subclasses for the scores at the top. You can use NSAttributedString/NSMutableAttributedString to create styled text, and use their drawInRect method to draw the text into the view. It would be a good idea to read this:

https://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CocoaDrawingGuide/Introduction/Introduction.html

And more specifically, this: https://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CocoaDrawingGuide/Text/Text.html#//apple_ref/doc/uid/TP40003290-CH209-BCIEEIGC

For the scrolling scores below, you will have to put the scores into an NSTableView, or an NSCollectionView (the latter is better if you want to customize the display) inside an NSScrollView. As for the automatic scrolling, NSScrollView has nothing built in to facilitate this. Most likely you are going to have to use an NSTimer that fires every few milliseconds, and uses NSScrollView's scrollToPoint: method to scroll gradually until you hit the bottom.

Independent Cocoa Developer, Macatomy Software
http://macatomy.com


On 2010-01-03, at 4:07 PM, email@hidden wrote:

> I have been asked to design a revolving scoreboard for a large Sporting Clays event. The plan is to have a MacBook connected to a large flat screen TV in the main tent. I will pull the scores from a CSV file (which is updated regularly) and sort them into arrays for display. Creating the on screen graphics is something I have not done much of with Cocoa. The organizers have asked for a full screen display and would like have the top 5 scores at the top of the screen and then scroll the rest of the field below these scores.
> I could punch this out with HTML and a bit of Javascript, but I thought it might be good to do have a play with Quartz.
> Can you please tell me how you good people might approach this?
> _______________________________________________
>
> 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

  • Follow-Ups:
    • Re: Revolving scoreboard
      • From: Scott Anguish <email@hidden>
References: 
 >Revolving scoreboard (From: email@hidden)

  • Prev by Date: Re: Revolving scoreboard
  • Next by Date: Re: Revolving scoreboard
  • Previous by thread: Re: Revolving scoreboard
  • Next by thread: Re: Revolving scoreboard
  • Index(es):
    • Date
    • Thread