|
Zrythm v2.0.0-DEV
a highly automated and intuitive digital audio workstation
|
The Zrythm GTK application. More...
#include <src/gui/backend/gtk_widgets/zrythm_app.h>


Public Member Functions | |
| ZrythmApp (int argc, const char **argv) | |
| Creates the application. | |
| void | set_font_scale (double font_scale) |
| void | check_for_updates () |
| Handles the logic for checking for updates on startup. | |
| int | prompt_for_project_func () |
| Unlike the init thread, this will run in the main GTK thread. | |
| bool | check_and_show_trial_limit_error () |
| Shows the trial limitation error message. | |
| void | init_recent_projects () |
| Initializes the array of recent projects in Zrythm app. | |
| void | install_action_accel (const std::string &primary, const std::string &secondary, const std::string &action_name) |
| Install accelerator for an action. | |
| std::string | get_primary_accel_for_action (const std::string &action_name) |
| Get the primary accelerator for an action. | |
| void | on_plugin_scan_finished () |
Static Public Member Functions | |
| static void | exit_response_callback (AdwDialog *dialog, gpointer user_data) |
| To be used to exit Zrythm using the "response" signal on a message dialog. | |
Data Fields | |
| Glib::RefPtr< Gtk::Settings > | default_settings_ |
| Default settings (got from gtk_settings_get_default()). | |
| MainWindowWidget * | main_window_ = nullptr |
| Main window. | |
| unsigned int | gtk_thread_id_ = std::numeric_limits<unsigned int>::max () |
| The GTK thread where the main GUI loop runs. | |
| std::unique_ptr< UiCaches > | ui_caches_ |
| bool | init_finished_ = false |
| Flag to set when initialization has finished. | |
| GreeterWidget * | greeter_ = nullptr |
| Greeter screen. | |
| bool | is_first_run_ = false |
| True if this is the first time Zrythm is runh. | |
| bool | have_svg_loader_ = false |
| std::string | audio_backend_ |
| Audio backend passed with –audio-backend=, if any. | |
| std::string | midi_backend_ |
| MIDI backend passed with –audio-backend=, if any. | |
| int | buf_size_ = 0 |
| Buffer size passed with –buf-size=, if any. | |
| int | samplerate_ = 0 |
| Samplerate passed with –samplerate=, if any. | |
| std::queue< std::string > | startup_error_queue_ |
| Messages to show when the main window is shown. | |
| std::mutex | startup_error_queue_mutex_ |
| std::string | output_file_ |
| Output file passed with –output. | |
| bool | pretty_print_ = false |
| Whether to pretty-print. | |
| int | argc_ = 0 |
| CLI args. | |
| char ** | argv_ = nullptr |
| std::string | appimage_runtime_path_ |
| AppImage runtime path, if AppImage build. | |
| bool | rt_priority_message_shown_ = false |
| Flag used to only show the RT priority message once. | |
| std::queue< ZrythmAppUiMessage > | project_load_message_queue_ |
| Queue for messages to be shown when the project loads. | |
| std::mutex | queue_mutex_ |
| BugReportDialogWidget * | bug_report_dialog_ = nullptr |
| Currently opened bug report dialog. | |
| std::unique_ptr< ProjectInitFlowManager > | project_init_flow_mgr_ |
| guint | project_autosave_source_id_ = 0 |
Protected Member Functions | |
| void | on_startup () override |
| First function that gets called afted CLI args are parsed and processed. | |
| void | on_activate () override |
| void | on_open (const Gio::Application::type_vec_files &files, const Glib::ustring &hint) override |
| Called when a filename is passed to the command line instead of activate. | |
| void | on_shutdown () override |
| Called immediately after the main GTK loop terminates. | |
The Zrythm GTK application.
Contains data that is only relevant to the GUI or command line.
Definition at line 49 of file zrythm_app.h.
| ZrythmApp::ZrythmApp | ( | int | argc, |
| const char ** | argv ) |
| bool ZrythmApp::check_and_show_trial_limit_error | ( | ) |
Shows the trial limitation error message.
|
overrideprotected |
Called when a filename is passed to the command line instead of activate.
Always gets called after startup and before the tasks.
|
overrideprotected |
Called immediately after the main GTK loop terminates.
This is also called manually on SIGINT.
|
overrideprotected |
First function that gets called afted CLI args are parsed and processed.
This gets called before open or activate.
| int ZrythmApp::prompt_for_project_func | ( | ) |
Unlike the init thread, this will run in the main GTK thread.
Do not put expensive logic here.
This should be ran after the expensive initialization has finished.
| std::string ZrythmApp::appimage_runtime_path_ |
AppImage runtime path, if AppImage build.
Definition at line 246 of file zrythm_app.h.
| int ZrythmApp::argc_ = 0 |
CLI args.
Definition at line 242 of file zrythm_app.h.
| char** ZrythmApp::argv_ = nullptr |
Definition at line 243 of file zrythm_app.h.
| std::string ZrythmApp::audio_backend_ |
Audio backend passed with –audio-backend=, if any.
Definition at line 219 of file zrythm_app.h.
| int ZrythmApp::buf_size_ = 0 |
Buffer size passed with –buf-size=, if any.
Definition at line 226 of file zrythm_app.h.
| BugReportDialogWidget* ZrythmApp::bug_report_dialog_ = nullptr |
Currently opened bug report dialog.
Definition at line 258 of file zrythm_app.h.
| Glib::RefPtr<Gtk::Settings> ZrythmApp::default_settings_ |
Default settings (got from gtk_settings_get_default()).
Definition at line 187 of file zrythm_app.h.
| GreeterWidget* ZrythmApp::greeter_ = nullptr |
Greeter screen.
Definition at line 206 of file zrythm_app.h.
| unsigned int ZrythmApp::gtk_thread_id_ = std::numeric_limits<unsigned int>::max () |
The GTK thread where the main GUI loop runs.
This is stored for identification purposes in other threads.
Definition at line 198 of file zrythm_app.h.
| bool ZrythmApp::have_svg_loader_ = false |
Definition at line 215 of file zrythm_app.h.
| bool ZrythmApp::init_finished_ = false |
Flag to set when initialization has finished.
Definition at line 203 of file zrythm_app.h.
| bool ZrythmApp::is_first_run_ = false |
True if this is the first time Zrythm is runh.
This remains true even after setting the corresponding GSettings value.
Definition at line 213 of file zrythm_app.h.
| MainWindowWidget* ZrythmApp::main_window_ = nullptr |
Main window.
Definition at line 190 of file zrythm_app.h.
| std::string ZrythmApp::midi_backend_ |
MIDI backend passed with –audio-backend=, if any.
Definition at line 223 of file zrythm_app.h.
| std::string ZrythmApp::output_file_ |
Output file passed with –output.
Definition at line 236 of file zrythm_app.h.
| bool ZrythmApp::pretty_print_ = false |
Whether to pretty-print.
Definition at line 239 of file zrythm_app.h.
| guint ZrythmApp::project_autosave_source_id_ = 0 |
Definition at line 262 of file zrythm_app.h.
| std::unique_ptr<ProjectInitFlowManager> ZrythmApp::project_init_flow_mgr_ |
Definition at line 260 of file zrythm_app.h.
| std::queue<ZrythmAppUiMessage> ZrythmApp::project_load_message_queue_ |
Queue for messages to be shown when the project loads.
Definition at line 254 of file zrythm_app.h.
| std::mutex ZrythmApp::queue_mutex_ |
Definition at line 255 of file zrythm_app.h.
| bool ZrythmApp::rt_priority_message_shown_ = false |
Flag used to only show the RT priority message once.
Definition at line 249 of file zrythm_app.h.
| int ZrythmApp::samplerate_ = 0 |
Samplerate passed with –samplerate=, if any.
Definition at line 229 of file zrythm_app.h.
| std::queue<std::string> ZrythmApp::startup_error_queue_ |
Messages to show when the main window is shown.
Definition at line 232 of file zrythm_app.h.
| std::mutex ZrythmApp::startup_error_queue_mutex_ |
Definition at line 233 of file zrythm_app.h.
| std::unique_ptr<UiCaches> ZrythmApp::ui_caches_ |
Definition at line 200 of file zrythm_app.h.