Skip to content

Commit

Permalink
rerun bindgen
Browse files Browse the repository at this point in the history
  • Loading branch information
thomcc committed Apr 4, 2021
1 parent 163244c commit de5496d
Show file tree
Hide file tree
Showing 2 changed files with 180 additions and 90 deletions.
133 changes: 88 additions & 45 deletions imgui-sys/src/bindings.rs
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
/* automatically generated by rust-bindgen 0.56.0 */
/* automatically generated by rust-bindgen 0.58.0 */

#![allow(nonstandard_style, clippy::all)]

#[repr(C)]
#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct __BindgenBitfieldUnit<Storage, Align> {
pub struct __BindgenBitfieldUnit<Storage> {
storage: Storage,
align: [Align; 0],
}
impl<Storage, Align> __BindgenBitfieldUnit<Storage, Align> {
impl<Storage> __BindgenBitfieldUnit<Storage> {
#[inline]
pub const fn new(storage: Storage) -> Self {
Self { storage, align: [] }
Self { storage }
}
}
impl<Storage, Align> __BindgenBitfieldUnit<Storage, Align>
impl<Storage> __BindgenBitfieldUnit<Storage>
where
Storage: AsRef<[u8]> + AsMut<[u8]>,
{
Expand Down Expand Up @@ -108,7 +107,7 @@ pub type ImGuiMouseCursor = cty::c_int;
pub type ImGuiSortDirection = cty::c_int;
pub type ImGuiStyleVar = cty::c_int;
pub type ImGuiTableBgTarget = cty::c_int;
pub type ImDrawCornerFlags = cty::c_int;
pub type ImDrawFlags = cty::c_int;
pub type ImDrawListFlags = cty::c_int;
pub type ImFontAtlasFlags = cty::c_int;
pub type ImGuiBackendFlags = cty::c_int;
Expand Down Expand Up @@ -139,6 +138,12 @@ pub type ImGuiInputTextCallback = ::core::option::Option<
>;
pub type ImGuiSizeCallback =
::core::option::Option<unsafe extern "C" fn(data: *mut ImGuiSizeCallbackData)>;
pub type ImGuiMemAllocFunc = ::core::option::Option<
unsafe extern "C" fn(sz: usize, user_data: *mut cty::c_void) -> *mut cty::c_void,
>;
pub type ImGuiMemFreeFunc = ::core::option::Option<
unsafe extern "C" fn(ptr: *mut cty::c_void, user_data: *mut cty::c_void),
>;
pub type ImWchar16 = cty::c_ushort;
pub type ImWchar = ImWchar16;
pub type ImU8 = cty::c_uchar;
Expand Down Expand Up @@ -411,7 +416,7 @@ pub const ImGuiInputTextFlags_CallbackCharFilter: ImGuiInputTextFlags_ = 512;
pub const ImGuiInputTextFlags_AllowTabInput: ImGuiInputTextFlags_ = 1024;
pub const ImGuiInputTextFlags_CtrlEnterForNewLine: ImGuiInputTextFlags_ = 2048;
pub const ImGuiInputTextFlags_NoHorizontalScroll: ImGuiInputTextFlags_ = 4096;
pub const ImGuiInputTextFlags_AlwaysInsertMode: ImGuiInputTextFlags_ = 8192;
pub const ImGuiInputTextFlags_AlwaysOverwrite: ImGuiInputTextFlags_ = 8192;
pub const ImGuiInputTextFlags_ReadOnly: ImGuiInputTextFlags_ = 16384;
pub const ImGuiInputTextFlags_Password: ImGuiInputTextFlags_ = 32768;
pub const ImGuiInputTextFlags_NoUndoRedo: ImGuiInputTextFlags_ = 65536;
Expand Down Expand Up @@ -871,7 +876,7 @@ pub struct ImGuiStyle {
pub AntiAliasedLinesUseTex: bool,
pub AntiAliasedFill: bool,
pub CurveTessellationTol: f32,
pub CircleSegmentMaxError: f32,
pub CircleTessellationMaxError: f32,
pub Colors: [ImVec4; 53usize],
}
impl Default for ImGuiStyle {
Expand All @@ -881,7 +886,7 @@ impl Default for ImGuiStyle {
}
impl ::core::fmt::Debug for ImGuiStyle {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
write ! (f , "ImGuiStyle {{ Alpha: {:?}, WindowPadding: {:?}, WindowRounding: {:?}, WindowBorderSize: {:?}, WindowMinSize: {:?}, WindowTitleAlign: {:?}, WindowMenuButtonPosition: {:?}, ChildRounding: {:?}, ChildBorderSize: {:?}, PopupRounding: {:?}, PopupBorderSize: {:?}, FramePadding: {:?}, FrameRounding: {:?}, FrameBorderSize: {:?}, ItemSpacing: {:?}, ItemInnerSpacing: {:?}, CellPadding: {:?}, TouchExtraPadding: {:?}, IndentSpacing: {:?}, ColumnsMinSpacing: {:?}, ScrollbarSize: {:?}, ScrollbarRounding: {:?}, GrabMinSize: {:?}, GrabRounding: {:?}, LogSliderDeadzone: {:?}, TabRounding: {:?}, TabBorderSize: {:?}, TabMinWidthForCloseButton: {:?}, ColorButtonPosition: {:?}, ButtonTextAlign: {:?}, SelectableTextAlign: {:?}, DisplayWindowPadding: {:?}, DisplaySafeAreaPadding: {:?}, MouseCursorScale: {:?}, AntiAliasedLines: {:?}, AntiAliasedLinesUseTex: {:?}, AntiAliasedFill: {:?}, CurveTessellationTol: {:?}, CircleSegmentMaxError: {:?}, Colors: [...] }}" , self . Alpha , self . WindowPadding , self . WindowRounding , self . WindowBorderSize , self . WindowMinSize , self . WindowTitleAlign , self . WindowMenuButtonPosition , self . ChildRounding , self . ChildBorderSize , self . PopupRounding , self . PopupBorderSize , self . FramePadding , self . FrameRounding , self . FrameBorderSize , self . ItemSpacing , self . ItemInnerSpacing , self . CellPadding , self . TouchExtraPadding , self . IndentSpacing , self . ColumnsMinSpacing , self . ScrollbarSize , self . ScrollbarRounding , self . GrabMinSize , self . GrabRounding , self . LogSliderDeadzone , self . TabRounding , self . TabBorderSize , self . TabMinWidthForCloseButton , self . ColorButtonPosition , self . ButtonTextAlign , self . SelectableTextAlign , self . DisplayWindowPadding , self . DisplaySafeAreaPadding , self . MouseCursorScale , self . AntiAliasedLines , self . AntiAliasedLinesUseTex , self . AntiAliasedFill , self . CurveTessellationTol , self . CircleSegmentMaxError)
write ! (f , "ImGuiStyle {{ Alpha: {:?}, WindowPadding: {:?}, WindowRounding: {:?}, WindowBorderSize: {:?}, WindowMinSize: {:?}, WindowTitleAlign: {:?}, WindowMenuButtonPosition: {:?}, ChildRounding: {:?}, ChildBorderSize: {:?}, PopupRounding: {:?}, PopupBorderSize: {:?}, FramePadding: {:?}, FrameRounding: {:?}, FrameBorderSize: {:?}, ItemSpacing: {:?}, ItemInnerSpacing: {:?}, CellPadding: {:?}, TouchExtraPadding: {:?}, IndentSpacing: {:?}, ColumnsMinSpacing: {:?}, ScrollbarSize: {:?}, ScrollbarRounding: {:?}, GrabMinSize: {:?}, GrabRounding: {:?}, LogSliderDeadzone: {:?}, TabRounding: {:?}, TabBorderSize: {:?}, TabMinWidthForCloseButton: {:?}, ColorButtonPosition: {:?}, ButtonTextAlign: {:?}, SelectableTextAlign: {:?}, DisplayWindowPadding: {:?}, DisplaySafeAreaPadding: {:?}, MouseCursorScale: {:?}, AntiAliasedLines: {:?}, AntiAliasedLinesUseTex: {:?}, AntiAliasedFill: {:?}, CurveTessellationTol: {:?}, CircleTessellationMaxError: {:?}, Colors: [...] }}" , self . Alpha , self . WindowPadding , self . WindowRounding , self . WindowBorderSize , self . WindowMinSize , self . WindowTitleAlign , self . WindowMenuButtonPosition , self . ChildRounding , self . ChildBorderSize , self . PopupRounding , self . PopupBorderSize , self . FramePadding , self . FrameRounding , self . FrameBorderSize , self . ItemSpacing , self . ItemInnerSpacing , self . CellPadding , self . TouchExtraPadding , self . IndentSpacing , self . ColumnsMinSpacing , self . ScrollbarSize , self . ScrollbarRounding , self . GrabMinSize , self . GrabRounding , self . LogSliderDeadzone , self . TabRounding , self . TabBorderSize , self . TabMinWidthForCloseButton , self . ColorButtonPosition , self . ButtonTextAlign , self . SelectableTextAlign , self . DisplayWindowPadding , self . DisplaySafeAreaPadding , self . MouseCursorScale , self . AntiAliasedLines , self . AntiAliasedLinesUseTex , self . AntiAliasedFill , self . CurveTessellationTol , self . CircleTessellationMaxError)
}
}
#[repr(C)]
Expand Down Expand Up @@ -1045,7 +1050,8 @@ pub struct ImGuiTableColumnSortSpecs {
pub ColumnUserID: ImGuiID,
pub ColumnIndex: ImS16,
pub SortOrder: ImS16,
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize], u8>,
pub _bitfield_align_1: [u8; 0],
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
pub __bindgen_padding_0: [u8; 3usize],
}
impl ImGuiTableColumnSortSpecs {
Expand All @@ -1063,9 +1069,8 @@ impl ImGuiTableColumnSortSpecs {
#[inline]
pub fn new_bitfield_1(
SortDirection: ImGuiSortDirection,
) -> __BindgenBitfieldUnit<[u8; 1usize], u8> {
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize], u8> =
Default::default();
) -> __BindgenBitfieldUnit<[u8; 1usize]> {
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
__bindgen_bitfield_unit.set(0usize, 8u8, {
let SortDirection: u32 = unsafe { ::core::mem::transmute(SortDirection) };
SortDirection as u64
Expand Down Expand Up @@ -1144,7 +1149,6 @@ pub union ImGuiStoragePair__bindgen_ty_1 {
pub val_i: cty::c_int,
pub val_f: f32,
pub val_p: *mut cty::c_void,
_bindgen_union_align: u64,
}
impl Default for ImGuiStoragePair__bindgen_ty_1 {
fn default() -> Self {
Expand Down Expand Up @@ -1254,17 +1258,21 @@ impl Default for ImDrawListSplitter {
unsafe { ::core::mem::zeroed() }
}
}
pub const ImDrawCornerFlags_None: ImDrawCornerFlags_ = 0;
pub const ImDrawCornerFlags_TopLeft: ImDrawCornerFlags_ = 1;
pub const ImDrawCornerFlags_TopRight: ImDrawCornerFlags_ = 2;
pub const ImDrawCornerFlags_BotLeft: ImDrawCornerFlags_ = 4;
pub const ImDrawCornerFlags_BotRight: ImDrawCornerFlags_ = 8;
pub const ImDrawCornerFlags_Top: ImDrawCornerFlags_ = 3;
pub const ImDrawCornerFlags_Bot: ImDrawCornerFlags_ = 12;
pub const ImDrawCornerFlags_Left: ImDrawCornerFlags_ = 5;
pub const ImDrawCornerFlags_Right: ImDrawCornerFlags_ = 10;
pub const ImDrawCornerFlags_All: ImDrawCornerFlags_ = 15;
pub type ImDrawCornerFlags_ = cty::c_uint;
pub const ImDrawFlags_None: ImDrawFlags_ = 0;
pub const ImDrawFlags_Closed: ImDrawFlags_ = 1;
pub const ImDrawFlags_RoundCornersTopLeft: ImDrawFlags_ = 16;
pub const ImDrawFlags_RoundCornersTopRight: ImDrawFlags_ = 32;
pub const ImDrawFlags_RoundCornersBottomLeft: ImDrawFlags_ = 64;
pub const ImDrawFlags_RoundCornersBottomRight: ImDrawFlags_ = 128;
pub const ImDrawFlags_RoundCornersNone: ImDrawFlags_ = 256;
pub const ImDrawFlags_RoundCornersTop: ImDrawFlags_ = 48;
pub const ImDrawFlags_RoundCornersBottom: ImDrawFlags_ = 192;
pub const ImDrawFlags_RoundCornersLeft: ImDrawFlags_ = 80;
pub const ImDrawFlags_RoundCornersRight: ImDrawFlags_ = 160;
pub const ImDrawFlags_RoundCornersAll: ImDrawFlags_ = 240;
pub const ImDrawFlags_RoundCornersDefault_: ImDrawFlags_ = 240;
pub const ImDrawFlags_RoundCornersMask_: ImDrawFlags_ = 496;
pub type ImDrawFlags_ = cty::c_uint;
pub const ImDrawListFlags_None: ImDrawListFlags_ = 0;
pub const ImDrawListFlags_AntiAliasedLines: ImDrawListFlags_ = 1;
pub const ImDrawListFlags_AntiAliasedLinesUseTex: ImDrawListFlags_ = 2;
Expand Down Expand Up @@ -1348,7 +1356,8 @@ impl ::core::fmt::Debug for ImFontConfig {
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct ImFontGlyph {
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize], u32>,
pub _bitfield_align_1: [u32; 0],
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
pub AdvanceX: f32,
pub X0: f32,
pub Y0: f32,
Expand Down Expand Up @@ -1398,9 +1407,8 @@ impl ImFontGlyph {
Colored: cty::c_uint,
Visible: cty::c_uint,
Codepoint: cty::c_uint,
) -> __BindgenBitfieldUnit<[u8; 4usize], u32> {
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize], u32> =
Default::default();
) -> __BindgenBitfieldUnit<[u8; 4usize]> {
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
__bindgen_bitfield_unit.set(0usize, 1u8, {
let Colored: u32 = unsafe { ::core::mem::transmute(Colored) };
Colored as u64
Expand Down Expand Up @@ -1451,11 +1459,12 @@ pub type ImFontAtlasFlags_ = cty::c_uint;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct ImFontAtlas {
pub Locked: bool,
pub Flags: ImFontAtlasFlags,
pub TexID: ImTextureID,
pub TexDesiredWidth: cty::c_int,
pub TexGlyphPadding: cty::c_int,
pub Locked: bool,
pub TexPixelsUseColors: bool,
pub TexPixelsAlpha8: *mut cty::c_uchar,
pub TexPixelsRGBA32: *mut cty::c_uint,
pub TexWidth: cty::c_int,
Expand All @@ -1478,7 +1487,7 @@ impl Default for ImFontAtlas {
}
impl ::core::fmt::Debug for ImFontAtlas {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
write ! (f , "ImFontAtlas {{ Locked: {:?}, Flags: {:?}, TexID: {:?}, TexDesiredWidth: {:?}, TexGlyphPadding: {:?}, TexPixelsAlpha8: {:?}, TexPixelsRGBA32: {:?}, TexWidth: {:?}, TexHeight: {:?}, TexUvScale: {:?}, TexUvWhitePixel: {:?}, Fonts: {:?}, CustomRects: {:?}, ConfigData: {:?}, TexUvLines: [...], FontBuilderIO: {:?}, FontBuilderFlags: {:?}, PackIdMouseCursors: {:?}, PackIdLines: {:?} }}" , self . Locked , self . Flags , self . TexID , self . TexDesiredWidth , self . TexGlyphPadding , self . TexPixelsAlpha8 , self . TexPixelsRGBA32 , self . TexWidth , self . TexHeight , self . TexUvScale , self . TexUvWhitePixel , self . Fonts , self . CustomRects , self . ConfigData , self . FontBuilderIO , self . FontBuilderFlags , self . PackIdMouseCursors , self . PackIdLines)
write ! (f , "ImFontAtlas {{ Flags: {:?}, TexID: {:?}, TexDesiredWidth: {:?}, TexGlyphPadding: {:?}, Locked: {:?}, TexPixelsUseColors: {:?}, TexPixelsAlpha8: {:?}, TexPixelsRGBA32: {:?}, TexWidth: {:?}, TexHeight: {:?}, TexUvScale: {:?}, TexUvWhitePixel: {:?}, Fonts: {:?}, CustomRects: {:?}, ConfigData: {:?}, TexUvLines: [...], FontBuilderIO: {:?}, FontBuilderFlags: {:?}, PackIdMouseCursors: {:?}, PackIdLines: {:?} }}" , self . Flags , self . TexID , self . TexDesiredWidth , self . TexGlyphPadding , self . Locked , self . TexPixelsUseColors , self . TexPixelsAlpha8 , self . TexPixelsRGBA32 , self . TexWidth , self . TexHeight , self . TexUvScale , self . TexUvWhitePixel , self . Fonts , self . CustomRects , self . ConfigData , self . FontBuilderIO , self . FontBuilderFlags , self . PackIdMouseCursors , self . PackIdLines)
}
}
#[repr(C)]
Expand Down Expand Up @@ -2791,7 +2800,7 @@ extern "C" {
label: *const cty::c_char,
flags: ImGuiTableColumnFlags,
init_width_or_weight: f32,
user_id: ImU32,
user_id: ImGuiID,
);
}
extern "C" {
Expand Down Expand Up @@ -3158,15 +3167,18 @@ extern "C" {
}
extern "C" {
pub fn igSetAllocatorFunctions(
alloc_func: ::core::option::Option<
unsafe extern "C" fn(sz: usize, user_data: *mut cty::c_void) -> *mut cty::c_void,
>,
free_func: ::core::option::Option<
unsafe extern "C" fn(ptr: *mut cty::c_void, user_data: *mut cty::c_void),
>,
alloc_func: ImGuiMemAllocFunc,
free_func: ImGuiMemFreeFunc,
user_data: *mut cty::c_void,
);
}
extern "C" {
pub fn igGetAllocatorFunctions(
p_alloc_func: *mut ImGuiMemAllocFunc,
p_free_func: *mut ImGuiMemFreeFunc,
p_user_data: *mut *mut cty::c_void,
);
}
extern "C" {
pub fn igMemAlloc(size: usize) -> *mut cty::c_void;
}
Expand Down Expand Up @@ -3570,7 +3582,7 @@ extern "C" {
p_max: ImVec2,
col: ImU32,
rounding: f32,
rounding_corners: ImDrawCornerFlags,
flags: ImDrawFlags,
thickness: f32,
);
}
Expand All @@ -3581,7 +3593,7 @@ extern "C" {
p_max: ImVec2,
col: ImU32,
rounding: f32,
rounding_corners: ImDrawCornerFlags,
flags: ImDrawFlags,
);
}
extern "C" {
Expand Down Expand Up @@ -3701,7 +3713,7 @@ extern "C" {
points: *const ImVec2,
num_points: cty::c_int,
col: ImU32,
closed: bool,
flags: ImDrawFlags,
thickness: f32,
);
}
Expand Down Expand Up @@ -3772,7 +3784,7 @@ extern "C" {
uv_max: ImVec2,
col: ImU32,
rounding: f32,
rounding_corners: ImDrawCornerFlags,
flags: ImDrawFlags,
);
}
extern "C" {
Expand All @@ -3788,7 +3800,12 @@ extern "C" {
pub fn ImDrawList_PathFillConvex(self_: *mut ImDrawList, col: ImU32);
}
extern "C" {
pub fn ImDrawList_PathStroke(self_: *mut ImDrawList, col: ImU32, closed: bool, thickness: f32);
pub fn ImDrawList_PathStroke(
self_: *mut ImDrawList,
col: ImU32,
flags: ImDrawFlags,
thickness: f32,
);
}
extern "C" {
pub fn ImDrawList_PathArcTo(
Expand Down Expand Up @@ -3832,7 +3849,7 @@ extern "C" {
rect_min: ImVec2,
rect_max: ImVec2,
rounding: f32,
rounding_corners: ImDrawCornerFlags,
flags: ImDrawFlags,
);
}
extern "C" {
Expand Down Expand Up @@ -3925,6 +3942,32 @@ extern "C" {
extern "C" {
pub fn ImDrawList__OnChangedVtxOffset(self_: *mut ImDrawList);
}
extern "C" {
pub fn ImDrawList__CalcCircleAutoSegmentCount(
self_: *mut ImDrawList,
radius: f32,
) -> cty::c_int;
}
extern "C" {
pub fn ImDrawList__PathArcToFastEx(
self_: *mut ImDrawList,
center: ImVec2,
radius: f32,
a_min_sample: cty::c_int,
a_max_sample: cty::c_int,
a_step: cty::c_int,
);
}
extern "C" {
pub fn ImDrawList__PathArcToN(
self_: *mut ImDrawList,
center: ImVec2,
radius: f32,
a_min: f32,
a_max: f32,
num_segments: cty::c_int,
);
}
extern "C" {
pub fn ImDrawData_ImDrawData() -> *mut ImDrawData;
}
Expand Down
Loading

0 comments on commit de5496d

Please sign in to comment.