-
Notifications
You must be signed in to change notification settings - Fork 0
/
ACEHeader.pch
executable file
·39 lines (28 loc) · 1.11 KB
/
ACEHeader.pch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
//
// ACEHeader.pch
// barcodeGMJ001
//
// Created by admin on 14/12/18.
// Copyright (c) 2014年 葛茂菁. All rights reserved.
//
#ifndef barcodeGMJ001_ACEHeader_pch
#define barcodeGMJ001_ACEHeader_pch
#define kURL @"请填写数据网站"
#define kRESULT @"1122345556789"
#define kX() ([[UIScreen mainScreen]applicationFrame].size.width / 8)
#define kY() ([[UIScreen mainScreen]applicationFrame].size.height / 8)
// 颜色(RGB)
#define RGBCOLOR(r, g, b) [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:1]
#define RGBACOLORA(r, g, b, a) [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:(a)]
// 16 -> 10 RGB
#define RGBCOLOR16TO10RGB(rgbValue)\
[UIColor colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 \
green:((float)((rgbValue & 0xFF00) >> 8))/255.0 \
blue:((float)(rgbValue & 0xFF))/255.0 \
alpha:1.0]
// 16 -> 10 RGB 带有alpha
#define RGBColorFromRGBWithAlpha(rgbValue,a) [UIColor \
colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 \
green:((float)((rgbValue & 0xFF00) >> 8))/255.0 \
blue:((float)(rgbValue & 0xFF))/255.0 alpha:a]
#endif