Files
TransPyC/includes/fltk/cfltk/include/cfltk2/cfl_surface.h
T
TermiNexus 6892183cc9 feat(fltk): 新增 FLTK 1.4 纯 extern FFI 绑定库(对接 cfltk C API)
- 生成 24 个 _cfl*.vp(10327 条 extern 声明)+ _types/_enums 常量

- __init__.vp 提供 Fl/Fl_Widget/Fl_Window/Fl_Button/Fl_Input/Fl_Text_Buffer/Fl_Group/Fl_Menu_Bar/Fl_Native_File_Chooser 等包装类

- 回调(Fl_Callback)按 bytes 不透明处理,菜单回调位传 t.CPtr(0)

- 新增 examples/hello.vp、dialog.vp 冒烟样例,26 个 .vp 全部通过 vast parse

- 内嵌 cfltk(C API 封装)与 FLTK 1.4 完整源码,构建目标 cfltk2
2026-09-01 19:53:54 +08:00

73 lines
1.9 KiB
C

#ifndef __CFL_SURFACE_H__
#define __CFL_SURFACE_H__
#ifdef __cplusplus
extern "C" {
#endif
typedef struct Fl_Surface_Device Fl_Surface_Device;
void Fl_Surface_Device_set_current(Fl_Surface_Device *self);
int Fl_Surface_Device_is_current(Fl_Surface_Device *self);
Fl_Surface_Device *Fl_Surface_Device_surface(void);
void Fl_Surface_Device_push_current(Fl_Surface_Device *new_current);
Fl_Surface_Device *Fl_Surface_Device_pop_current(void);
typedef struct Fl_Image_Surface Fl_Image_Surface;
Fl_Image_Surface *Fl_Image_Surface_new(int w, int h, int high_res);
void Fl_Image_Surface_delete(Fl_Image_Surface *s);
void Fl_Image_Surface_set_current(Fl_Image_Surface *self);
int Fl_Image_Surface_is_current(Fl_Image_Surface *self);
void *Fl_Image_Surface_image(Fl_Image_Surface *self);
void *Fl_Image_Surface_highres_image(Fl_Image_Surface *self);
void Fl_Image_Surface_origin(Fl_Image_Surface *self, int *x, int *y);
void Fl_Image_Surface_set_origin(Fl_Image_Surface *self, int x, int y);
void Fl_Image_Surface_rescale(Fl_Image_Surface *self);
void Fl_Image_Surface_draw(
Fl_Image_Surface *self, void *widget, int delta_x, int delta_y
);
void Fl_Image_Surface_draw_decorated_window(
Fl_Image_Surface *self, void *widget, int delta_x, int delta_y
);
typedef struct Fl_SVG_File_Surface Fl_SVG_File_Surface;
Fl_SVG_File_Surface *
Fl_SVG_File_Surface_new(int width, int height, const char *file);
void Fl_SVG_File_Surface_delete(Fl_SVG_File_Surface *self);
void Fl_SVG_File_Surface_origin(Fl_SVG_File_Surface *self, int x, int y);
int Fl_SVG_File_Surface_printable_rect(
Fl_SVG_File_Surface *self, int *w, int *h
);
void Fl_SVG_File_Surface_draw(
Fl_SVG_File_Surface *self, void *widget, int delta_x, int delta_y
);
void Fl_SVG_File_Surface_draw_decorated_window(
Fl_SVG_File_Surface *self, void *widget, int delta_x, int delta_y
);
#ifdef __cplusplus
}
#endif
#endif