bors-servo
c441d916e1
Auto merge of #560 - fcfangcc:release-0.23.4, r=jdm
...
Release for core-graphics
Release core-graphics version to 0.22.4
Include #554 , I urgently need to use it. Thanks 😃
2023-05-29 04:29:36 +02:00
fcfangcc
4c11545a87
release core-graphics 0.22.4
2023-05-29 09:39:15 +08:00
bors-servo
d254cec065
Auto merge of #554 - fcfangcc:feat-screenCaptureAccess, r=jdm
...
Add binding for ScreenCaptureAccess
Add binding for [CGRequestScreenCaptureAccess](https://developer.apple.com/documentation/coregraphics/3656524-cgrequestscreencaptureaccess ) and [CGPreflightScreenCaptureAccess](https://developer.apple.com/documentation/coregraphics/3656523-cgpreflightscreencaptureaccess )
to check if the app has screen recording permission on macOS
2023-05-24 15:53:08 +02:00
bors-servo
8b982fdd57
Auto merge of #548 - burtonageo:update_foreign_types, r=jdm
...
Update `foreign-types` crate to v0.5
Splits out the `foreign-types` part of https://github.com/servo/core-foundation-rs/pull/545
2023-05-24 15:42:31 +02:00
fcfangcc
d8b6ff1723
Add ScreenCaptureAccess struct
2023-05-24 21:23:55 +08:00
fcfangcc
2784e317bd
Add binding for ScreenCaptureAccess
2023-05-24 15:50:12 +08:00
mtfcd
75f424f81a
Add function from apple document, and add a method image_for_rect for convinient to use.
2023-04-27 00:04:55 -04:00
George Burton
6ddf5cadcc
Update foreign-types crate to v0.5
2023-04-25 22:15:52 +01:00
Alex Touchet
1632edee66
Use SPDX license format
2023-04-02 22:43:22 -07:00
Josh Leeb-du Toit
49aa01d437
Add binding for CGEventTapPostEvent
...
This change adds the binding for CGEventTapPostEvent and adds a wrapper
function CGEvent::post_from_tap to call the core-graphics function.
2023-03-21 15:38:43 +11:00
Alexander Ekdahl
6a0cbbfb3d
Add all color space names
...
Adds all of the non-deprecated color space names found at: https://developer.apple.com/documentation/coregraphics/cgcolorspace/color_space_names
2022-12-24 00:41:31 +01:00
Hein Rutjes
342af5e6a9
Add CGContextResetClip
2022-10-07 07:43:07 -04:00
Hein Rutjes
3213c3e3f3
Add CGContextSetAlpha
2022-10-06 13:50:31 -04:00
Mads Marquart
560da05fef
Add CoreGraphics FFI used by winit
2022-09-05 13:33:55 +02:00
Alex Touchet
5143684bb5
Fix listed core-graphics homepage
2022-05-26 08:25:16 -04:00
Mikaela Szekely
65b1efcd5d
Publish core-graphics
2021-10-27 20:31:00 -06:00
bors-servo
f7e0b97e0b
Auto merge of #436 - AsafFisher:master, r=jrmuizel
...
Add CGEventTap
https://github.com/servo/core-graphics-rs/issues/111
2021-05-26 13:18:34 -04:00
Phil Dennis-Jordan
c519abad47
Adds function for fetching ID of a core_graphics::display::CGDisplayMode
...
This adds a mode_id() function on CGDisplayMode which returns the unique (to that display) integer ID the system uses to identify the display mode. It internally calls down to CGDisplayModeGetIODisplayModeID() in the CoreGraphics framework. The FFI for this function was previously missing and has also been added.
2021-03-26 15:49:20 +01:00
Jeff Muizelaar
d9403529d0
Expose CGFontCopyVariations and CGFontCopyVariationAxes
2021-02-09 20:02:46 -05:00
Asaf Fisher
532a3214be
core-graphics: event: Add tests to CGEventTap
2021-01-25 19:58:22 +02:00
Asaf Fisher
19671d30c2
core-graphics: Add CGEventTap object to create an event tap
2021-01-25 19:58:22 +02:00
Jeff Muizelaar
7ce88888a0
Bump core-graphics version
2020-12-08 11:50:48 -05:00
Jeff Muizelaar
dc588497db
Fix the type of Arc::from_raw().
...
Previously we were mistakenly creating an Arc<c_void> instead of an
Arc<T>. This also changes the test to catch this problem.
2020-10-14 13:29:28 -04:00
Josh Matthews
d3336c3a21
Version bumps for cocoa, core-foundation-sys, core-foundation, core-text, core-graphics-types, core-graphics.
2020-09-15 12:19:56 -04:00
Josh Matthews
95d071234c
Bump core-graphics to 0.22.0, core-text to 19.0.0, cocoa to 0.23.0.
2020-09-15 12:15:41 -04:00
Kornel Lesiński
71a0d68abf
Fix docs.rs build
2020-08-26 17:28:10 +01:00
Jeff Muizelaar
edb7a8c7fc
Add cocoa-foundation crate
...
This should let gfx-metal-rust avoid depending on core-graphics
2020-07-17 22:48:21 -04:00
Jeff Muizelaar
8bf741bc82
Make CGDataProvider::from_buffer more generic
...
This lets us use more types than just Vec<u8> and should avoid any
compatibility breaks. It also adds a test that ensures
the memory gets released.
2020-07-16 18:07:33 -04:00
Josh Matthews
762a01b90f
Major version update for core-foundation-sys and all other dependencies.
2020-06-29 11:45:17 -04:00
Josh Matthews
56d8b6c161
Major version change for core-foundation, core-graphics, io-surface, core-text, cocoa.
2020-06-29 11:03:28 -04:00
Josh Matthews
d196c0c4c8
Publish core-graphics 0.19.2.
2020-06-27 15:05:02 -04:00
Francesca Lovebloom
9ae9c5e3f7
Fix build on iOS
2020-06-26 13:15:17 -07:00
Josh Matthews
25840d6dc5
Publish core-graphics 0.19.1.
2020-06-26 11:18:38 -04:00
Colin Rofls
334c234539
Add CGContext::set_/get_interpolation_quality
2020-05-12 14:43:38 -04:00
Colin Rofls
db5fa6b85d
Add CGContext::clip_to_mask
2020-05-09 14:10:03 -04:00
Kornel
acf2c86930
Fix style warnings
2020-05-08 11:42:06 +01:00
brunohgouveia
8fb46bd58a
Add CGContextRetain and CGContextRelease
...
Add function to create CGContext from existing ::sys::CGContextRef pointer
2020-04-16 00:21:03 +01:00
brunohgouveia
999128fc71
Add CGContextSetShadow and CGContextSetShadowWithColor to CGContext
2020-04-14 00:12:00 +01:00
bors-servo
1e06588c4b
Auto merge of #365 - brunogouveia:add-cg-gradient, r=jdm
...
Add CGGradient and CGContext gradient draw functions
This PR adds the following missing APIs:
- Added [CGGradient](https://developer.apple.com/documentation/coregraphics/cggradient ) in the `core_graphics::gradient` module.
- Added [CGContextDrawLinearGradient](https://developer.apple.com/documentation/coregraphics/1454782-cgcontextdrawlineargradient ) and [CGContextDrawRadialGradient](https://developer.apple.com/documentation/coregraphics/1455923-cgcontextdrawradialgradient ) in the `core_graphics::context` module.
2020-04-13 16:52:02 -04:00
bors-servo
8a02888d43
Auto merge of #367 - brunogouveia:add-text-line, r=jdm
...
Add missing APIs to CTLine
Added the following missing APIs to [CTLine](https://developer.apple.com/documentation/coretext/ctline ):
- CTLineDraw
- CTLineGetImageBounds
- CTLineGetStringIndexForPosition
- CTLineGetOffsetForStringIndex
Added `CGContextSetTextPosition` to `CGContext`.
Added `CGTextFillStrokeClip` to `CGTextDrawingMode`.
2020-04-13 16:46:04 -04:00
brunohgouveia
1f4c983cee
Add missing APIs to CTLine
2020-04-13 21:25:53 +01:00
brunohgouveia
ca3c41846e
Add missing APIs to CGAffineTransform
2020-04-13 20:54:50 +01:00
brunohgouveia
c503b4eddb
Add CGGradient and CGContext gradient draw functions
2020-04-13 20:43:50 +01:00
Max Brunsfeld
f763977a76
Move doc comment to struct inside bitflags invocation
2020-01-09 08:38:33 -08:00
Max Brunsfeld
d95d3fa743
Fix miscellaneous compile warnings
2020-01-08 20:47:41 -08:00
bors-servo
0a3ac83c1b
Auto merge of #349 - wez:timertypes, r=jdm
...
Fix CFRunLoop types to avoid UB
A number of callback functions associated with the CFRunLoop types are
allowed to be NULL to evoke default behavior.
Prior to this commit the definition of those structs prevented passing
in null which meant resorting to transmute or other tricks to
effectively set null, but with recent compiler versions the compiler
emits `ud2` instructions and triggers a fault at runtime.
The correct resolution for this is to define these fields as `Option`al
callbacks and that is what this commit does.
I've used this approach successfully here in another project:
Refs: https://github.com/wez/wezterm/commit/398f333c32fb1ff4ccd9cc001a66ae22522eb60c
I've bumped up the version for the crate as part of this commit
because it effectively changes the API around these structs.
2019-11-12 18:08:51 -05:00
Wez Furlong
6574b12d4a
more version bumps!
2019-11-12 14:16:35 -08:00
Qifan Lu
d3a097f2a4
Use dyn for dynamic dispatch
2019-11-11 20:59:26 -08:00
Qifan Lu
e438fc54b9
Use ? instead of try macro
2019-11-11 20:57:09 -08:00
Wez Furlong
e7f687e3d4
moar version bumps
2019-11-11 20:29:01 -08:00