mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-21 15:01:01 +01:00
Two-finger pinch now does both zoom (distance change) and Z-axis rotation (angle change) simultaneously. Adds demo_view_rotate_z() for direct Z-axis rotation from touch input. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
68 lines
1.3 KiB
C
68 lines
1.3 KiB
C
/*
|
|
* Copyright 2012 Google, Inc. All Rights Reserved.
|
|
*
|
|
* Google Author(s): Behdad Esfahbod
|
|
*/
|
|
|
|
#ifndef DEMO_VIEW_H
|
|
#define DEMO_VIEW_H
|
|
|
|
#include "demo-common.h"
|
|
#include "demo-buffer.h"
|
|
#include "demo-renderer.h"
|
|
|
|
typedef struct demo_view_t demo_view_t;
|
|
|
|
#ifndef HB_GPU_NO_GLFW
|
|
demo_view_t *
|
|
demo_view_create (demo_renderer_t *renderer, GLFWwindow *window);
|
|
#endif
|
|
|
|
demo_view_t *
|
|
demo_view_create_headless (demo_renderer_t *renderer,
|
|
int fb_width, int fb_height,
|
|
int win_width, int win_height);
|
|
|
|
void
|
|
demo_view_destroy (demo_view_t *vu);
|
|
|
|
|
|
void
|
|
demo_view_reset (demo_view_t *vu);
|
|
|
|
void
|
|
demo_view_reshape_func (demo_view_t *vu, int width, int height);
|
|
|
|
void
|
|
demo_view_key_func (demo_view_t *vu, int key, int scancode, int action, int mods);
|
|
|
|
void
|
|
demo_view_char_func (demo_view_t *vu, unsigned int codepoint);
|
|
|
|
void
|
|
demo_view_mouse_func (demo_view_t *vu, int button, int action, int mods);
|
|
|
|
void
|
|
demo_view_scroll_func (demo_view_t *vu, double xoffset, double yoffset);
|
|
|
|
void
|
|
demo_view_rotate_z (demo_view_t *vu, double angle);
|
|
|
|
void
|
|
demo_view_motion_func (demo_view_t *vu, double x, double y);
|
|
|
|
void
|
|
demo_view_print_help (demo_view_t *vu);
|
|
|
|
void
|
|
demo_view_display (demo_view_t *vu, demo_buffer_t *buffer);
|
|
|
|
void
|
|
demo_view_setup (demo_view_t *vu);
|
|
|
|
bool
|
|
demo_view_should_redraw (demo_view_t *vu);
|
|
|
|
|
|
#endif /* DEMO_VIEW_H */
|