Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-20645

QML Linting Problem

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P2: Important P2: Important
    • None
    • Qt Creator 4.6.2
    • Quick / QML Support
    • None
    • Ubuntu 18.04
    • Linux/X11

      Hello,

      The problem

      The problem is about the qml linter. When I setting some properties to `ChartView` from `QtCharts 2.0`, The linter will give mistake error reports.

      More specificly, the properties i am setting are `margin` and `legend`. For example, i want custom the `ChartView` by using code below:

      ChartView{
       id:test
       margin.top:3
       legend.alignment: Qt.AlignBottom
       }

      The `Qt Creator` embedded qml linter will report errors, like this

      ChartView{
       id:test
       margin.top:3 error: "margin" doesn't have members.(M17)
       legend.alignment: Qt.AlignBottom error: "legend" doesn't have members.(M17)
       }

      I am sure that syntax is correct because they really do their job (change the legend position and decrease default margin size)

      BUG reproduction

      I can reproduct the bug by opening the offical DEMO `qmlchart`, and open `view1.qml` , the qml linter will give me an error at line 44.This line is

      legend.alignment: Qt.AlignBottom

      Error info is:

      "legend" doesn't have members.(M17)

      and I have uploaded an screenshot showing this BUG.

      Thank you.

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

            mabenell Marco Benelli
            curry 瀚骋 刘
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes