提交 62596245 authored 作者: 袁静春's avatar 袁静春

提交:修改iOS磅单打印尺寸偏小的问题;

上级 5198289b
......@@ -287,6 +287,7 @@
NSString *content = [m objectForKey:@"content"];
NSNumber *x = ![m objectForKey:@"x"]?@0 : [m objectForKey:@"x"];
NSNumber *y = ![m objectForKey:@"y"]?@0 : [m objectForKey:@"y"];
NSNumber *imageWidth = ![m objectForKey:@"width"]?@300 : [m objectForKey:@"width"];
if([@"text" isEqualToString:type]){
[command addTextwithX:[x intValue] withY:[y intValue] withFont:@"TSS24.BF2" withRotation:0 withXscal:1 withYscal:1 withText:content];
......@@ -297,7 +298,7 @@
}else if([@"image" isEqualToString:type]){
NSData *decodeData = [[NSData alloc] initWithBase64EncodedString:content options:0];
UIImage *image = [UIImage imageWithData:decodeData];
[command addBitmapwithX:[x intValue] withY:[y intValue] withMode:0 withWidth:300 withImage:image];
[command addBitmapwithX:[x intValue] withY:[y intValue] withMode:0 withWidth:[imageWidth intValue] withImage:image];
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论