<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk" version="4.0"/>
<object class="AdwApplicationWindow" id="main_window">
<property name="accessible-role">79</property>
<property name="content">
<object class="AdwNavigationView" id="main_window_pages">
<child>
<object class="AdwNavigationPage" id="main_page">
<property name="child">
<object class="AdwToolbarView">
<property name="content">
<object class="GtkScrolledWindow" id="main_scrollview">
<property name="child">
<object class="GtkBox" id="layout_box">
<property name="homogeneous">true</property>
<property name="margin-bottom">15</property>
<property name="margin-end">15</property>
<property name="margin-start">15</property>
<property name="margin-top">15</property>
<property name="spacing">15</property>
<child type="primary">
<object class="GtkBox" id="left_column">
<property name="orientation">1</property>
<property name="spacing">15</property>
<child>
<object class="AdwPreferencesGroup" id="identify_section">
<property name="title" translatable="yes">Recognize songs</property>
<child>
<object class="AdwActionRow" id="recognize_file_row">
<property name="activatable">true</property>
<property name="activatable-widget">recognize_file_button</property>
<property name="selectable">false</property>
<property name="title" translatable="yes">Recognize from file</property>
<child>
<object class="GtkButton" id="recognize_file_button">
<property name="action-name">win.recognize-file</property>
<property name="child">
<object class="AdwButtonContent">
<property name="icon-name">folder-new-symbolic</property>
<property name="label" translatable="yes">Pick a file...</property>
</object>
</property>
</object>
</child>
</object>
</child>
<child>
<object class="AdwPreferencesRow" id="spinner_row">
<property name="activatable">false</property>
<property name="margin-end">7</property>
<property name="margin-start">7</property>
<property name="margin-top">7</property>
<property name="selectable">false</property>
<property name="visible">false</property>
<child>
<object class="GtkSpinner">
<property name="margin-bottom">7</property>
<property name="spinning">true</property>
</object>
</child>
</object>
</child>
<child>
<object class="AdwSwitchRow" id="microphone_switch">
<property name="activatable">true</property>
<property name="selectable">false</property>
<property name="title" translatable="yes">Recognize from microphone</property>
<property name="visible">false</property>
<signal name="notify::active" handler="microphone_option_switched"/>
</object>
</child>
<child>
<object class="AdwSwitchRow" id="loopback_switch">
<property name="activatable">true</property>
<property name="selectable">false</property>
<property name="title" translatable="yes">Recognize from my speakers</property>
<property name="visible">false</property>
<signal name="notify::active" handler="loopback_options_switched"/>
</object>
</child>
<child>
<object class="GtkLabel" id="no_network_message">
<property name="attributes">0 -1 weight medium, 0 -1 foreground #a4a400000000</property>
<property name="label" translatable="yes">Shazam servers are not reachable, are you connected?</property>
<property name="margin-top">5</property>
<property name="visible">false</property>
</object>
</child>
<child>
<object class="GtkLabel" id="rate_limited_message">
<property name="attributes">0 -1 weight bold, 0 -1 foreground #a4a400000000</property>
<property name="label" translatable="yes">ERROR: Your IP has been rate-limited</property>
<property name="margin-top">5</property>
<property name="visible">false</property>
</object>
</child>
</object>
</child>
<child>
<object class="AdwPreferencesGroup" id="results_section">
<property name="title" translatable="yes">Recognition results</property>
<property name="visible">false</property>
<child>
<object class="AdwPreferencesRow" id="results_row">
<property name="activatable">false</property>
<property name="selectable">false</property>
<child>
<object class="GtkBox">
<property name="margin-bottom">7</property>
<property name="margin-end">7</property>
<property name="margin-start">7</property>
<property name="margin-top">7</property>
<property name="orientation">1</property>
<property name="spacing">7</property>
<child>
<object class="GtkLabel" id="results_label">
<property name="attributes">0 -1 weight bold</property>
<property name="ellipsize">3</property>
<property name="label">Artist - Song name</property>
<property name="natural-wrap-mode">2</property>
<property name="selectable">true</property>
</object>
</child>
<child>
<object class="GtkImage" id="results_image">
<property name="pixel-size">160</property>
</object>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="AdwActionRow" id="search_youtube_row">
<property name="activatable">true</property>
<property name="activatable-widget">search_youtube_button</property>
<property name="selectable">false</property>
<property name="title" translatable="yes">Search on YouTube</property>
<child>
<object class="GtkButton" id="search_youtube_button">
<property name="action-name">win.search-youtube</property>
<property name="child">
<object class="AdwButtonContent">
<property name="icon-name">search-symbolic</property>
<property name="label" translatable="yes">Search...</property>
</object>
</property>
</object>
</child>
</object>
</child>
</object>
</child>
</object>
</child>
<child type="secondary">
<object class="GtkBox" id="right_column">
<property name="orientation">1</property>
<property name="spacing">15</property>
<child>
<object class="AdwPreferencesGroup" id="input_device_section">
<property name="header-suffix">
<object class="GtkButton" id="refresh_devices">
<property name="action-name">win.refresh-devices</property>
<property name="icon-name">view-refresh-symbolic</property>
<property name="tooltip-text" translatable="yes">Refresh available devices</property>
</object>
</property>
<property name="title" translatable="yes">Audio input</property>
<property name="visible">false</property>
<child>
<object class="AdwComboRow" id="audio_inputs">
<property name="factory">
<object class="GtkBuilderListItemFactory" id="audio_inputs_factory">
<property name="bytes"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="GtkListItem">
<property name="child">
<object class="GtkLabel">
<property name="xalign">0</property>
<property name="ellipsize">3</property>
<binding name="label">
<lookup name="display_name" type="ListedDevice">
<lookup name="item" type="GtkListItem">GtkListItem</lookup>
</lookup>
</binding>
</object>
</property>
</template>
</interface>]]></property>
</object>
</property>
<property name="model">
<object class="GListStore" id="audio_inputs_model"></object>
</property>
<property name="title" translatable="yes">Device</property>
<property name="title-lines">1</property>
<signal name="notify::selected-item" handler="input_device_switched"/>
</object>
</child>
<child>
<object class="AdwPreferencesRow" id="volume_row">
<property name="activatable">false</property>
<property name="selectable">false</property>
<child>
<object class="GtkBox">
<property name="margin-bottom">15</property>
<property name="margin-end">15</property>
<property name="margin-start">15</property>
<property name="margin-top">15</property>
<property name="spacing">15</property>
<child>
<object class="GtkLabel" id="volume_label">
<property name="label" translatable="yes">Volume:</property>
</object>
</child>
<child>
<object class="GtkProgressBar" id="volume_gauge">
<property name="hexpand">true</property>
<property name="valign">3</property>
</object>
</child>
</object>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="AdwPreferencesGroup" id="history_section">
<property name="header-suffix">
<object class="GtkMenuButton" id="history_params">
<property name="has-tooltip">true</property>
<property name="icon-name">preferences-system</property>
<property name="menu-model">history_menu_model</property>
<property name="tooltip-text" translatable="yes">History options...</property>
</object>
</property>
<property name="title" translatable="yes">Recognition history</property>
<child>
<object class="AdwPreferencesRow" id="history_row">
<property name="child">
<object class="GtkScrolledWindow">
<property name="child">history_view</property>
<child>
<object class="GtkColumnView" id="history_view">
<property name="accessible-role">26</property>
<property name="css-classes">column_view</property>
<property name="model">
<object class="GtkSingleSelection" id="history_selection">
<property name="autoselect">false</property>
<property name="can-unselect">true</property>
</object>
</property>
<property name="show-column-separators">true</property>
<property name="show-row-separators">true</property>
<child>
<object class="GtkColumnViewColumn" id="song_name_cell">
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="setup" handler="history_cell_setup_cb" object="song_name_cell"/>
<signal name="bind" handler="history_cell_bind_cb" object="song_name_cell"/>
</object>
</property>
<property name="id">song_name</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Song name</property>
</object>
</child>
<child>
<object class="GtkColumnViewColumn" id="album_cell">
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="bind" handler="history_cell_bind_cb" object="album_cell"/>
<signal name="setup" handler="history_cell_setup_cb" object="album_cell"/>
</object>
</property>
<property name="id">album</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Album</property>
</object>
</child>
<child>
<object class="GtkColumnViewColumn" id="recognition_date_cell">
<property name="expand">true</property>
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="bind" handler="history_cell_bind_cb" object="recognition_date_cell"/>
<signal name="setup" handler="history_cell_setup_cb" object="recognition_date_cell"/>
</object>
</property>
<property name="id">recognition_date</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Recognition date</property>
</object>
</child>
</object>
</child>
</object>
</property>
<property name="height-request">200</property>
</object>
</child>
<child>
<object class="AdwPreferencesRow" id="favorites_button">
<property name="accessible-role">3</property>
<property name="action-name">navigation.push</property>
<property name="action-target">'favorites_tag'</property>
<property name="child">
<object class="GtkLabel">
<property name="attributes">0 -1 weight medium</property>
<property name="label" translatable="yes">View favorites</property>
<property name="margin-bottom">10</property>
<property name="margin-top">10</property>
</object>
</property>
</object>
</child>
</object>
</child>
</object>
</child>
</object>
</property>
</object>
</property>
<child type="top">
<object class="AdwHeaderBar" id="title_bar">
<child type="end">
<object class="GtkMenuButton" id="menu_button">
<property name="accessible-role">34</property>
<property name="has-tooltip">true</property>
<property name="icon-name">open-menu-symbolic</property>
<property name="menu-model">main_menu_model</property>
<property name="primary">true</property>
<property name="tooltip-text" translatable="yes">Application menu</property>
</object>
</child>
</object>
</child>
</object>
</property>
<property name="title">SongRec</property>
</object>
</child>
<child>
<object class="AdwNavigationPage" id="favorites_page">
<property name="child">
<object class="AdwToolbarView">
<property name="content">
<object class="GtkScrolledWindow">
<property name="child">favorites_view</property>
<child>
<object class="GtkColumnView" id="favorites_view">
<property name="accessible-role">26</property>
<property name="css-classes">column_view</property>
<property name="model">
<object class="GtkSingleSelection" id="favorites_selection">
<property name="autoselect">false</property>
<property name="can-unselect">true</property>
</object>
</property>
<property name="show-column-separators">true</property>
<property name="show-row-separators">true</property>
<child>
<object class="GtkColumnViewColumn" id="favorites_song_name_cell">
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="bind" handler="history_cell_bind_cb" object="favorites_song_name_cell"/>
<signal name="setup" handler="history_cell_setup_cb" object="favorites_song_name_cell"/>
</object>
</property>
<property name="id">song_name</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Song name</property>
</object>
</child>
<child>
<object class="GtkColumnViewColumn" id="favorites_album_cell">
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="bind" handler="history_cell_bind_cb" object="favorites_album_cell"/>
<signal name="setup" handler="history_cell_setup_cb" object="favorites_album_cell"/>
</object>
</property>
<property name="id">album</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Album</property>
</object>
</child>
<child>
<object class="GtkColumnViewColumn" id="favorites_recognition_date_cell">
<property name="expand">true</property>
<property name="factory">
<object class="GtkSignalListItemFactory">
<signal name="bind" handler="history_cell_bind_cb" object="favorites_recognition_date_cell"/>
<signal name="setup" handler="history_cell_setup_cb" object="favorites_recognition_date_cell"/>
</object>
</property>
<property name="id">recognition_date</property>
<property name="resizable">true</property>
<property name="title" translatable="yes">Recognition date</property>
</object>
</child>
</object>
</child>
</object>
</property>
<child type="top">
<object class="AdwHeaderBar" id="favorites_titlebar"></object>
</child>
<child type="bottom">
<object class="GtkActionBar" id="favorites_actions">
<child>
<object class="GtkButton" id="favorites_export_csv">
<property name="action-name">win.export-favorites-to-csv</property>
<child>
<object class="AdwButtonContent">
<property name="icon-name">x-office-spreadsheet-symbolic</property>
<property name="label" translatable="yes">Export to CSV</property>
</object>
</child>
</object>
</child>
</object>
</child>
</object>
</property>
<property name="tag">favorites_tag</property>
<property name="title" translatable="yes">Favorites</property>
</object>
</child>
<child>
<object class="AdwNavigationPage" id="settings_page">
<property name="child">
<object class="AdwToolbarView">
<property name="content">
<object class="AdwPreferencesPage">
<child>
<object class="AdwPreferencesGroup" id="general_preferences">
<property name="title" translatable="yes">General preferences</property>
<child>
<object class="AdwSwitchRow" id="notification_setting">
<property name="action-name">win.notification-setting</property>
<property name="subtitle" translatable="yes">Notify when a new song is recognized or network error is encountered</property>
<property name="title" translatable="yes">Show notifications</property>
</object>
</child>
<child>
<object class="AdwSwitchRow" id="no_dupes_setting">
<property name="action-name">win.no-dupes-setting</property>
<property name="subtitle" translatable="yes">Bump a song to the top of the history list and remove the former entry when the same song is detected multiple times</property>
<property name="title" translatable="yes">No duplicates in history</property>
</object>
</child>
<child>
<object class="AdwSwitchRow" id="systray_setting">
<property name="action-name">win.systray-setting</property>
<property name="subtitle" translatable="yes">When closing the window, minimize to system tray using KSNI instead of closing the app. Please note that you may have to increase the "request interval" setting when leaving SongRec running in the background to reduce your changes of getting rate-limited.</property>
<property name="title" translatable="yes">Minimize to system tray</property>
<property name="visible">false</property>
</object>
</child>
</object>
</child>
<child>
<object class="AdwPreferencesGroup" id="network_preferences">
<property name="title" translatable="yes">Network preferences</property>
<child>
<object class="AdwSpinRow" id="interval_setting">
<property name="adjustment">
<object class="GtkAdjustment" id="interval_value">
<property name="lower">1</property>
<property name="page-increment">1</property>
<property name="page-size">1</property>
<property name="step-increment">1</property>
<property name="upper">513</property>
<property name="value">8</property>
<signal name="value-changed" handler="interval_changed"/>
</object>
</property>
<property name="climb-rate">1</property>
<property name="numeric">true</property>
<property name="snap-to-ticks">true</property>
<property name="subtitle" translatable="yes">By default 8, increase if you are rate-limited</property>
<property name="title" translatable="yes">Shazam interval between requests in seconds</property>
<property name="update-policy">1</property>
</object>
</child>
<child>
<object class="AdwSwitchRow" id="mpris_setting">
<property name="action-name">win.mpris-setting</property>
<property name="has-tooltip">true</property>
<property name="subtitle" translatable="yes">MPRIS will display information about recognized songs in places like the GNOME or KDE control panel</property>
<property name="title" translatable="yes">Enable MPRIS</property>
<property name="visible">false</property>
</object>
</child>
</object>
</child>
<child>
<object class="AdwPreferencesGroup" id="search_preferences">
<property name="title" translatable="yes">Search preferences</property>
<child>
<object class="AdwEntryRow" id="search_engine_name">
<property name="title" translatable="yes">Custom search engine action</property>
<signal name="changed" handler="search_engine_action_changed"/>
</object>
</child>
<child>
<object class="AdwEntryRow" id="search_engine_url">
<property name="title" translatable="yes">Custom search engine URL</property>
<signal name="changed" handler="search_engine_url_changed"/>
</object>
</child>
</object>
</child>
</object>
</property>
<child type="top">
<object class="AdwHeaderBar"></object>
</child>
</object>
</property>
<property name="tag">settings_tag</property>
<property name="title" translatable="yes">Settings</property>
</object>
</child>
</object>
</property>
<property name="default-height">570</property>
<property name="default-width">977</property>
<property name="icon-name">re.fossplant.songrec</property>
<property name="startup-id">re.fossplant.songrec</property>
<property name="title">SongRec</property>
<property name="visible">true</property>
<child>
<object class="AdwBreakpoint" id="main_page_breakpoint">
<condition>max-width: 800px</condition>
<setter object="layout_box" property="orientation">1</setter>
<setter object="layout_box" property="homogeneous">false</setter>
</object>
</child>
</object>
<menu id="main_menu_model">
<section id="menu_section">
<item>
<attribute name="action">win.notification-setting</attribute>
<attribute name="label" translatable="yes">Show notifications</attribute>
</item>
<item>
<attribute name="action">navigation.push</attribute>
<attribute name="label" translatable="yes">_Preferences...</attribute>
<attribute name="target">settings_tag</attribute>
</item>
</section>
<section>
<item>
<attribute name="action">win.show-about</attribute>
<attribute name="label" translatable="yes">About...</attribute>
</item>
</section>
</menu>
<object class="AdwAboutDialog" id="about_dialog">
<property name="application-icon">custom_icon</property>
<property name="application-name">SongRec</property>
<property name="debug-info-filename">songrec-debug-info.txt</property>
<property name="developer-name">Marin Moulinier - Fossplant.re</property>
<property name="developers">Marin Moulinier https://moulinier.dev/
Contributors https://github.com/marin-m/SongRec/graphs/contributors</property>
<property name="issue-url">https://github.com/marin-m/SongRec/issues/new/choose</property>
<property name="license-type">3</property>
<property name="support-url">https://matrix.to/#/#songrec:matrix.org</property>
<property name="translator-credits">SongRec translators https://github.com/marin-m/SongRec/tree/main/translations</property>
<property name="visible">false</property>
<property name="website">https://songrec.fossplant.re/</property>
<signal name="closed" handler="about_dialog_closed"/>
</object>
<menu id="history_menu_model">
<item>
<attribute name="action">win.export-to-csv</attribute>
<attribute name="label" translatable="yes">Export to CSV</attribute>
</item>
<item>
<attribute name="action">win.wipe-history</attribute>
<attribute name="label" translatable="yes">Delete history</attribute>
</item>
</menu>
<object class="GtkFileDialog" id="file_picker">
<property name="title" translatable="yes">Select a file to recognize</property>
</object>
<object class="GtkPopoverMenu" id="history_context_menu">
<property name="menu-model">history_context_model</property>
</object>
<menu id="history_context_model">
<section>
<item>
<attribute name="action">history-menu.copy-artist-track</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy artist and track</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-artist</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy artist</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-track-name</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy track name</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-album</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy album</attribute>
</item>
</section>
<section>
<item>
<attribute name="action">history-menu.search-on-youtube</attribute>
<attribute name="icon">search-symbolic</attribute>
<attribute name="label" translatable="yes">Search on YouTube</attribute>
</item>
</section>
<section>
<item>
<attribute name="action">history-menu.remove-from-history</attribute>
<attribute name="icon">edit-delete-symbolic</attribute>
<attribute name="label" translatable="yes">Delete from History</attribute>
</item>
<item>
<attribute name="action">history-menu.add-to-favorites</attribute>
<attribute name="icon">favorite-new-symbolic</attribute>
<attribute name="label" translatable="yes">Add to Favorites</attribute>
</item>
</section>
</menu>
<menu id="history_context_model_faved">
<section>
<item>
<attribute name="action">history-menu.copy-artist-track</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy artist and track</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-artist</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy artist</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-track-name</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy track name</attribute>
</item>
<item>
<attribute name="action">history-menu.copy-album</attribute>
<attribute name="icon">edit-copy-symbolic</attribute>
<attribute name="label" translatable="yes">Copy album</attribute>
</item>
</section>
<section>
<item>
<attribute name="action">history-menu.search-on-youtube</attribute>
<attribute name="icon">search-symbolic</attribute>
<attribute name="label" translatable="yes">Search on YouTube</attribute>
</item>
</section>
<section>
<item>
<attribute name="action">history-menu.remove-from-favorites</attribute>
<attribute name="icon">edit-delete-symbolic</attribute>
<attribute name="label" translatable="yes">Remove from Favorites</attribute>
</item>
</section>
</menu>
<object class="GtkShortcutsWindow" id="shortcuts_window">
<property name="child">
<object class="GtkShortcutsSection">
<property name="title">shortcuts</property>
<child>
<object class="GtkShortcutsGroup">
<property name="title" translatable="yes" context="General section in the Shortcuts window">General</property>
<child>
<object class="GtkShortcutsShortcut">
<property name="accelerator"><Ctrl>Q</property>
<property name="action-name">win.close</property>
<property name="title" translatable="yes" context="In the shortcuts window">Close the application</property>
</object>
</child>
<child>
<object class="GtkShortcutsShortcut">
<property name="accelerator"><Ctrl>O</property>
<property name="action-name">win.recognize-file</property>
<property name="title" translatable="yes" context="In the shortcuts window">Recognize from a file</property>
</object>
</child>
<child>
<object class="GtkShortcutsShortcut">
<property name="accelerator"><Primary>comma</property>
<property name="action-name">win.show-preferences</property>
<property name="title" translatable="yes" context="In the shortcuts window">Show preferences</property>
</object>
</child>
<child>
<object class="GtkShortcutsShortcut">
<property name="accelerator"><Primary>question</property>
<property name="action-name">win.display-shortcuts</property>
<property name="title" translatable="yes" context="In the shortcuts window">Display shortcuts</property>
</object>
</child>
<child>
<object class="GtkShortcutsShortcut">
<property name="accelerator">F10</property>
<property name="action-name">win.show-menu</property>
<property name="title" translatable="yes" context="win.show-menu">Show menu</property>
</object>
</child>
</object>
</child>
</object>
</property>
<property name="destroy-with-parent">true</property>
<property name="focus-visible">false</property>
<property name="hide-on-close">true</property>
<property name="modal">true</property>
<property name="transient-for">main_window</property>
</object>
</interface>