1

The Sound Recorder app of GNOME has this in-window hint at start-up. Sound Recorder Screeshot How do I do this? I was browsing through the source code and found that it is written either in Vala or Javascript (not sure). Also, I want to put the hint inside the GtkListBox (Sound Recorder's is inside a list box too). How would I go about doing this in the C binding of GTK+?

1 Answer 1

1

According to their repo (I searched the hint string in there), they are using GtkStack widget with GtkStackPages:

<object class="AdwToastOverlay" id="toastOverlay">
  <property name="child">
    <object class="GtkStack" id="mainStack">
      <property name="hexpand">True</property>
      <property name="vexpand">True</property>
      <child>
        <object class="GtkStackPage">
          <property name="name">empty</property>
          <property name="child">
            <object class="AdwStatusPage" id="emptyPage">
              <property name="title" translatable="yes">Add Recordings</property>
              <property name="description" translatable="yes">Use the &lt;b&gt;Record&lt;/b&gt; button to make sound recordings</property>
            </object>
          </property>
        </object>
      </child>

It seems that GtkStack was available with GTK3, but not GtkStackPage (Gtk4 only).

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.