# cbindgen configuration for Flywheel C bindings

language = "C"

# Include only the ffi module
include_guard = "FLYWHEEL_H"
autogen_warning = "/* WARNING: This file is auto-generated by cbindgen. Do not edit. */"

# Generate documentation
documentation = true
documentation_style = "c99"

# Style settings
braces = "SameLine"
line_length = 100
tab_width = 4

# Type naming
style = "Both"

# Include version info
after_includes = """
#define FLYWHEEL_VERSION "0.1.0"
#define FLYWHEEL_VERSION_MAJOR 0
#define FLYWHEEL_VERSION_MINOR 1
#define FLYWHEEL_VERSION_PATCH 0
"""

[export]
include = [
    "FlywheelResult",
    "FlywheelEventType",
    "FlywheelKeyEvent",
    "FlywheelResizeEvent",
    "FlywheelEvent",
]

[export.rename]
"FlywheelEngine" = "FlywheelEngine"
"FlywheelStream" = "FlywheelStream"
"FlywheelBuffer" = "FlywheelBuffer"

[fn]
# Rename pattern for FFI functions
rename_args = "SnakeCase"

[struct]
# Derive PartialEq for simple structs
derive_eq = true

[enum]
# Use simple integer representation
rename_variants = "ScreamingSnakeCase"
