Skip to main content

engage/generated/unity_engine/text_core/
glyphrect.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "unity_engine-text_core-glyphrect-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::system::{
9        object::{IObject, Object},
10        valuetype::{IValueType, ValueType},
11    };
12
13    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/unity_engine/text_core/glyphrect/GlyphRect.md"))]
14    #[repr(C)]
15    #[derive(::core::clone::Clone, ::core::marker::Copy)]
16    pub struct GlyphRect {
17        pub m_x: i32,
18        pub m_y: i32,
19        pub m_width: i32,
20        pub m_height: i32,
21    }
22    impl ::unity::ClassIdentity for GlyphRect {
23        const NAME: &'static str = "GlyphRect";
24        const NAMESPACE: &'static str = "UnityEngine.TextCore";
25
26        fn class() -> ::unity::Class {
27            static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
28            *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
29        }
30    }
31    impl ::unity::IlType for GlyphRect {
32        fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
33            &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
34        }
35    }
36    impl GlyphRect {
37        #[inline]
38        pub fn s_zero_glyph_rect() -> crate::unity_engine::text_core::glyphrect::GlyphRect {
39            static OFFSET: ::std::sync::OnceLock<usize> = ::std::sync::OnceLock::new();
40            let __offset = ::unity::cached_field_offset_static::<Self>(&OFFSET, "s_ZeroGlyphRect");
41            ::unity::static_field_get_value_at_offset(<Self as ::unity::ClassIdentity>::class(), __offset)
42        }
43
44        #[inline]
45        pub fn set_s_zero_glyph_rect(value: crate::unity_engine::text_core::glyphrect::GlyphRect) {
46            static OFFSET: ::std::sync::OnceLock<usize> = ::std::sync::OnceLock::new();
47            let __offset = ::unity::cached_field_offset_static::<Self>(&OFFSET, "s_ZeroGlyphRect");
48            ::unity::static_field_set_value_at_offset(<Self as ::unity::ClassIdentity>::class(), __offset, value);
49        }
50    }
51}
52
53#[cfg(feature = "unity_engine-text_core-glyphrect-types")]
54pub use __types::*;
55
56#[cfg(feature = "unity_engine-text_core-glyphrect")]
57impl GlyphRect {
58    #[doc = "`get_zero()` overload"]
59    pub fn get_zero() -> crate::unity_engine::text_core::glyphrect::GlyphRect {
60        unsafe {
61            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e5e0usize)as*mut u8,crate::unity_engine::text_core::glyphrect::GlyphRect;
62            )
63        }
64    }
65
66    #[doc = "`.cctor()` overload"]
67    pub fn cctor() -> () {
68        unsafe {
69            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e7f0usize)as*mut u8,();
70            )
71        }
72    }
73}
74
75#[cfg(feature = "unity_engine-text_core-glyphrect")]
76impl GlyphRect {
77    #[doc = "`get_x()` overload"]
78    pub fn get_x(&mut self) -> i32 {
79        unsafe {
80            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e5a0usize)as*mut u8,i32;
81(*mut GlyphRect)self as*mut GlyphRect)
82        }
83    }
84
85    #[doc = "`get_y()` overload"]
86    pub fn get_y(&mut self) -> i32 {
87        unsafe {
88            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e5b0usize)as*mut u8,i32;
89(*mut GlyphRect)self as*mut GlyphRect)
90        }
91    }
92
93    #[doc = "`get_width()` overload"]
94    pub fn get_width(&mut self) -> i32 {
95        unsafe {
96            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e5c0usize)as*mut u8,i32;
97(*mut GlyphRect)self as*mut GlyphRect)
98        }
99    }
100
101    #[doc = "`get_height()` overload"]
102    pub fn get_height(&mut self) -> i32 {
103        unsafe {
104            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e5d0usize)as*mut u8,i32;
105(*mut GlyphRect)self as*mut GlyphRect)
106        }
107    }
108
109    #[doc = "`.ctor(i32, i32, i32, i32)` overload"]
110    pub fn ctor(
111        &mut self,
112        x: impl ::core::convert::Into<i32>,
113        y: impl ::core::convert::Into<i32>,
114        width: impl ::core::convert::Into<i32>,
115        height: impl ::core::convert::Into<i32>,
116    ) -> () {
117        unsafe {
118            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e650usize)as*mut u8,();
119(*mut GlyphRect)self as*mut GlyphRect,(i32)::core::convert::Into::into(x),(i32)::core::convert::Into::into(y),(i32)::core::convert::Into::into(width),(i32)::core::convert::Into::into(height))
120        }
121    }
122
123    #[doc = "`GetHashCode()` overload"]
124    pub fn get_hash_code(&mut self) -> i32 {
125        unsafe {
126            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e660usize)as*mut u8,i32;
127(*mut GlyphRect)self as*mut GlyphRect)
128        }
129    }
130
131    #[doc = "`Equals(crate::system::object::Object)` overload"]
132    pub fn equals(&mut self, obj: impl ::core::convert::Into<crate::system::object::Object>) -> bool {
133        unsafe {
134            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e6d0usize)as*mut u8,bool;
135(*mut GlyphRect)self as*mut GlyphRect,(crate::system::object::Object)::core::convert::Into::into(obj))
136        }
137    }
138
139    #[doc = "`Equals(crate::unity_engine::text_core::glyphrect::GlyphRect)` overload"]
140    pub fn equals_2(&mut self, other: impl ::core::convert::Into<crate::unity_engine::text_core::glyphrect::GlyphRect>) -> bool {
141        unsafe {
142            ::unity::il2cpp_call!((::unity::module_base()+0x3f2e750usize)as*mut u8,bool;
143(*mut GlyphRect)self as*mut GlyphRect,(crate::unity_engine::text_core::glyphrect::GlyphRect)::core::convert::Into::into(other))
144        }
145    }
146}
147
148#[cfg(feature = "unity_engine-text_core-glyphrect")]
149impl GlyphRect {
150    pub fn get_x_method_info() -> &'static ::unity::il2cpp::MethodInfo {
151        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
152    }
153
154    pub fn get_y_method_info() -> &'static ::unity::il2cpp::MethodInfo {
155        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
156    }
157
158    pub fn get_width_method_info() -> &'static ::unity::il2cpp::MethodInfo {
159        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
160    }
161
162    pub fn get_height_method_info() -> &'static ::unity::il2cpp::MethodInfo {
163        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
164    }
165
166    pub fn get_zero_method_info() -> &'static ::unity::il2cpp::MethodInfo {
167        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
168    }
169
170    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
171        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
172    }
173
174    pub fn get_hash_code_method_info() -> &'static ::unity::il2cpp::MethodInfo {
175        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
176    }
177
178    pub fn equals_method_info() -> &'static ::unity::il2cpp::MethodInfo {
179        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
180    }
181
182    pub fn equals_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
183        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
184    }
185
186    pub fn cctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
187        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
188    }
189}
190
191#[cfg(feature = "unity_engine-text_core-glyphrect")]
192#[doc(hidden)]
193pub mod prelude {
194    pub use super::GlyphRect;
195    #[cfg(feature = "system-object")]
196    pub use crate::system::object::IObjectMethods;
197    #[cfg(feature = "system-valuetype")]
198    pub use crate::system::valuetype::IValueTypeMethods;
199    pub use crate::system::{object::IObject, valuetype::IValueType};
200}