Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-120250

qmlls: Snippet completion for bindings

    XMLWordPrintable

Details

    • Task
    • Resolution: Unresolved
    • P3: Somewhat important
    • 6.8
    • 6.7
    • QML: Tooling
    • None

    Description

      We should investigate whether it makes sense to add snippets for binding completions.

      Some ideas:

      • when completing a property name of the current type, automatically insert a snippet with a `: ` but place the cursor before, so after using the completion it should look like `myProperty<cursor> : someValue`
      • when completing a QML type (for bindings to the default property, do as above but add the `{}` braces: `MyItem<cursor> {}`
      • when completing a qualified name: suggest the entire name (and do not stop at dots, if possible), such that `QQ.Item` (when `import QtQuick as QQ`), `font.family`. This allows to also insert the `: {}` or `: value` at the same time, which is quite nice for our current parser.
        • One could also suggest the `{}` completion when completing only `font` to get the grouped 'grouped properties' syntax
        • check if that does not generate way too much completions, it could be unhandy for the user if the completion is too full of stuff

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              qtqmlteam Qt Qml Team User
              sami.shalayel Sami Shalayel
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes