isVerticallyCentered
垂直方向で中心に置かれているかを返します
解説
垂直方向で中心に置かれているかを返します。
返り値
( BOOL )
YES/NO
引数
フレームワーク
ApplicationKit
クラス
NSPrintInfo
Instance Methods
使用可能
10.0
参照
- isHorizontallyCentered
- setVerticallyCentered:
例文
#import "MyObject.h" @implementation MyObject - (IBAction)myAction:(id)sender { NSPrintInfo *pInfo = [NSPrintInfo sharedPrintInfo] ; NSPageLayout *pageLayout = [NSPageLayout pageLayout]; [pInfo setVerticalPagination:NSAutoPagination]; [pageLayout beginSheetWithPrintInfo:pInfo modalForWindow:[sender window] delegate:self didEndSelector:@selector(didEndPageLayout) contextInfo:nil ]; if ([pInfo isVerticallyCentered]) { NSLog(@"YES"); }else{ NSLog(@"NO"); } } -(void)didEndPageLayout { NSLog(@"close"); } @end