• 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
registerUnitWithName incorrect steps
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

registerUnitWithName incorrect steps


  • Subject: registerUnitWithName incorrect steps
  • From: Ruben Smits <email@hidden>
  • Date: Wed, 25 Feb 2004 16:00:33 +0100

Hi,

I want to display my own rulerView with units increasing in steps of 5. At this moment it displays millimeters in steps of 32.

I register this unit in my [NSApplication applicationDidFinishLoading] with the call
///////////////
NSArray *stepUpCycle = [NSArray arrayWithObjects:[NSNumber numberWithFloat:2.0], nil];
NSArray *stepDownCycle = [NSArray arrayWithObjects:/*[NSNumber numberWithFloat:0.5], */[NSNumber numberWithFloat:0.25], nil];
[NSRulerView registerUnitWithName:@"Millimeters" abbreviation:NSLocalizedStringFromTable(@"mm", @"metrics", @"") unitToPointsConversionFactor:(72.0 / 25.4) stepUpCycle:stepUpCycle stepDownCycle:stepDownCycle];

////////////////
Why does this display the units in steps of 32, instead of steps of 5, or 2?


-----------
Ruben
-----------
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Prev by Date: CFPreferences and byhost preferences
  • Next by Date: Re: Line numbers in IDE
  • Previous by thread: CFPreferences and byhost preferences
  • Next by thread: NSComboBox and dataSource
  • Index(es):
    • Date
    • Thread