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

Forums

OverviewFelgo 3 Support (Qt 5) › Dialog and InputDialogs

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #24005

    nks (baumemo)

    Hi,

    I tested the Dialog component and found out that the Dialog Component has different behavior to the InputDialog.

    1. Overlay in Dialog has less opacity than in InputDialog
    2. The Dialog has problems with the splitview of NavigationStack. The white line of the splitview is always on top of the dialog. Changing z doesn’t help

    In general the InputDialogs is very custom. Is there code available to get a InputDialog for instance inputTextSingleLine byusing Dialog?

    #24006

    Filippo

    Hi Sergej,

     

    thanks for reaching out to us. If you prefer the look of standard Dialog you can use it to build your own custom version. Just take a look at this and add the required components, such as AppTextInput.

     

    I’d also suggest taking a look at NativeDialog which will invoke a native system dialog. For simple usecases, this is probably the best solution.

    #24009

    nks (baumemo)

    Hi Filippo,

    thanks again for your answer. The Dialog has problems with the splitview of NavigationStack. The white line of the splitview is always on top of the dialog. Changing z doesn’t help. This problem (it seems to be bug) stops me to build a custom Dialog. The opacity of the overlay can be changed only with an additional Rectangle which is not very clean. Is there a reason why Dialog and InputDialog has different behavior in that points.

    #24012

    Filippo

    Hello again Sergej,

     

    I’ve been able to see your issue live. I think what you see is related to z ordering, which is not global but related to neighbors. Have you tried moving the dialog up to an upper level in the hierarcy so that it’s no longer inside the NavigationStack? Something along these lines:

     

    import Felgo 3.0
    import QtQuick 2.0
    
    App {
      id: app
    
      Dialog {
        id: customDialog
        title: "Do you think this is awesome?"
        positiveActionLabel: "Yes"
        negativeActionLabel: "No"
        onCanceled: title = "Think again!"
        z: 2
      }
    
      Navigation {
        NavigationItem {
          title: "List Page"
          icon: IconType.list
    
          NavigationStack {
            splitView: true
    
            ListPage {
              title: "List Page"
              model: [
                { text: "Item #1" },
                { text: "Item #2" }
              ]
            }
          }
        }
      }
    
      Component.onCompleted: customDialog.open()
    }
    

     

    #24028

    nks (baumemo)

    Thank you, that solves the problem.

Viewing 5 posts - 1 through 5 (of 5 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