-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMacSupport.h
More file actions
executable file
·59 lines (41 loc) · 2.1 KB
/
Copy pathMacSupport.h
File metadata and controls
executable file
·59 lines (41 loc) · 2.1 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*************************************************************************************
cpl - cross-platform library - v. 0.1.0.
Copyright (C) 2016 Janus Lynggaard Thorborg (www.jthorborg.com)
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
See \licenses\ for additional details on licenses associated with this program.
**************************************************************************************
file:MacSupport.h
Since Objective-C and C++ doesn't always easily mix, access to the NSApi
has been stuffed into its own source file.
*************************************************************************************/
#ifndef CPL_MACSUPPORT_H
#define CPL_MACSUPPORT_H
#include <cstdlib>
struct OSXExtendedScreenInfo
{
// true if display is confirmable digital
bool displayIsDigital;
// gamma correction values for each channel, 1.2 .. 2.2
double redGamma, blueGamma, greenGamma;
// average colour gamma, 1.2 .. 2.2
double averageGamma;
// see AppleFontSmoothing system defaults. 0 is none, 1 .. 4 is variying degrees.
int fontSmoothingLevel;
// screen rotation, counterclockwise, in _degrees_
double screenRotation;
// can be kDisplaySubPixelLayoutRGB, kDisplaySubPixelLayoutBGR or kDisplaySubPixelLayoutUndefined
unsigned int subpixelOrientation;
};
bool GetExtendedScreenInfo(long x, long y, OSXExtendedScreenInfo * info);
int MacBox(void * hwndParent, const char *text, const char *caption, int type);
std::size_t GetBundlePath(char * buf, std::size_t bufsize);
#endif