1

下にタプクカレンダー画像を添付しています

以下のコードで試してみましたが、画像が設定されていません。

TKCalendarMonthView *calendar = [[TKCalendarMonthView alloc] init];

calendar.backgroundColor=[UIColor colorWithPatternImage:[UIImage imageNamed:@"fishimage.png"]];

"前もって感謝します"

4

2 に答える 2

4

いいえ Tapkuカレンダーは日付番号を含むボタン/ビューの集まり(かもしれません)なので、全体のイメージを変えることはできません。ただし、クラスのメソッドに従って、月の変化矢印の画像を変更できますUIImage+TKCategory.m

+ (UIImage*) imageNamedTK:(NSString*)str{

    CGFloat s = 1.0f;
    if([[UIScreen mainScreen] respondsToSelector:@selector(scale)]){
        s = [[UIScreen mainScreen] scale];
    }

    //NSString *path = [NSString stringWithFormat:@"%@%@.png",str,s > 1 ? @"@2x":@""];
    return [UIImage imageWithCGImage:[[UIImage imageNamed:@"img.jpg"]CGImage] scale:s orientation:UIImageOrientationUp]; // put here specific image name for display !

}
于 2013-01-11T13:08:27.387 に答える
3

画像を置き換えるだけでコーディングを変更する必要はありません

TapkuLibrary.bundle に移動 --> 画像 --> カレンダー AND Rplace your image with "Month Calendar Date Tile.png"

また

TKCalendarMonthView.m のコードを変更

tileImage = [UIImage imageNamed:@"fishimage.png"];

tileImage = [UIImage imageWithContentsOfFile:TKBUNDLE(@"calendar/Month Calendar Date Tile.png")];
于 2013-11-16T09:56:22.047 に答える