Zrythm
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
custom_button.h File Reference

Custom button to be drawn inside drawing areas. More...

#include <gtk/gtk.h>
Include dependency graph for custom_button.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  CustomButtonWidget
 Custom button to be drawn inside drawing areas. More...
 

Macros

#define CUSTOM_BUTTON_WIDGET_MAX_TRANSITION_FRAMES   9
 

Enumerations

enum  CustomButtonWidgetState {
  CUSTOM_BUTTON_WIDGET_STATE_NORMAL , CUSTOM_BUTTON_WIDGET_STATE_HOVERED , CUSTOM_BUTTON_WIDGET_STATE_ACTIVE , CUSTOM_BUTTON_WIDGET_STATE_TOGGLED ,
  CUSTOM_BUTTON_WIDGET_STATE_SEMI_TOGGLED
}
 
enum  CustomButtonWidgetOwner { CUSTOM_BUTTON_WIDGET_OWNER_TRACK , CUSTOM_BUTTON_WIDGET_OWNER_LANE , CUSTOM_BUTTON_WIDGET_OWNER_AT }
 

Functions

CustomButtonWidgetcustom_button_widget_new (const char *icon_name, int size)
 Creates a new track widget from the given track.
 
void custom_button_widget_draw (CustomButtonWidget *self, GtkSnapshot *snapshot, double x, double y, CustomButtonWidgetState state)
 
void custom_button_widget_draw_with_text (CustomButtonWidget *self, GtkSnapshot *snapshot, double x, double y, double width, CustomButtonWidgetState state)
 
void custom_button_widget_set_text (CustomButtonWidget *self, PangoLayout *layout, char *text, const char *font_descr)
 Sets the text and layout to draw the text width.
 
void custom_button_widget_free (CustomButtonWidget *self)
 

Detailed Description

Custom button to be drawn inside drawing areas.

Definition in file custom_button.h.