title: Create dynamic object from string, with variables as anchor property values
body: <p>In a function property of an element with <code>id: window</code>, I create dynamic objects as follows:</p>
  
  <pre><code>Qt.createQmlObject(
      'import QtQuick 2.3; Rectangle {color: "#00FF00"; width: 1; anchors.right: '+i+'; height:1; anchors.bottom: '+i+'; }',
      window, "dynamicPixels");
  </code></pre>
  
  <p>where <code>i</code> is the iterating variable of a loop containing this snippet.</p>
  
  <p>When I attempt to do some calculation with <code>i</code>, and use that as the value in the dynamic object, it complains:</p>
  
  <blockquote>
    <p>Unexpected token: 'numeric literal'</p>
  </blockquote>
  
  <p>I tried <code>Math.round()</code> thinking it might somehow have become double (even though the calculation involved only <code>int</code>s), but without change.</p>
  
  <p>However, when I reduced the line to just <code>i</code> to make my post here clearer, I get the different error:</p>
  
  <blockquote>
    <p>Invalid property assignment: unsupported type "QQuickAnchorLine"</p>
  </blockquote>
  
  <p>So do I have deeper problems - can I not use anchors at all in a dynamic object?</p>