-
Notifications
You must be signed in to change notification settings - Fork 50
Expand file tree
/
Copy pathScreen.java
More file actions
52 lines (44 loc) · 1.39 KB
/
Screen.java
File metadata and controls
52 lines (44 loc) · 1.39 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
package io.github.humbleui.jwm;
import io.github.humbleui.types.*;
import lombok.*;
import org.jetbrains.annotations.*;
import org.jetbrains.annotations.ApiStatus;
@Data
public class Screen {
/**
* <p>Application-wide platform-specific screen identifier.</p>
*/
public final long _id;
/**
* <p>Describes, if this screen is primary.</p>
* <p>Primary screen has top-left corner in general is global screen space origin.</p>
*/
public final boolean _isPrimary;
/**
* <p>Screen bounds in pixels in the global screen space coordinates.</p>
*/
public final IRect _bounds;
/**
* <p>Area in absolute pixels of the screen excluding dock/menubar</p>
*/
public final IRect _workArea;
/**
* <p>UI and text elements scale for display on this screen</p>
*/
public final float _scale;
/**
* <p>Get the ICC color profile data for this screen.</p>
* <p>Currently supported on macOS and Windows. Returns null on other platforms.</p>
*
* @return ICC profile data as byte array, or null if not available
*/
@Nullable
public byte[] getICCProfile() {
if (Platform.CURRENT == Platform.MACOS || Platform.CURRENT == Platform.WINDOWS) {
return _nGetICCProfile(_id);
}
return null;
}
@ApiStatus.Internal
private static native byte[] _nGetICCProfile(long screenId);
}