Learn what Felgo offers to help your business succeed. Start your free evaluation today! Felgo for Your Business


OverviewFelgo 3 Support (Qt 5) › How to add a button to Dialog title bar?

Tagged: ,

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #20065


    I’d like to add a button to the Dialog title bar, similar to using

    rightBarItem : NavigationBarItem {}

    inside a Page {}. When not using Felgo, it seems one can add

    header : Item {}

    to get the same effect, however when using Felgo, Dialog {} doesn’t recognize the ‘header’ property. I can’t find any alternatives other than maybe somehow getting anchors to put it where I want no matter the screen resolution. I would definitely prefer something a little more elegant.

    Thank you,



    Felgo Team

    Hi Eric,

    following interface design guidelines, it is not supposed to have a button in the dialog title, thus we will also not add this option directly to the component. However, as you mentioned, you can use anchoring to move a custom component to the header, like this:

    import Felgo 3.0
    import QtQuick 2.9
    App {
      onInitTheme: {
      Page {
        Dialog {
          id: dialog
          title: "Test"
          AppButton {
            text: "Button"
            flat: true
            anchors.right: parent.right
            anchors.top: parent.top
            anchors.topMargin: -dp(48)
          AppText {
            width: parent.width
            text: "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."
            padding: dp(15)


Viewing 2 posts - 1 through 2 (of 2 total)

RSS feed for this thread

You must be logged in to reply to this topic.

Qt_Technology_Partner_RGB_475 Qt_Service_Partner_RGB_475_padded