Not entirely sure how to do this but:

Qt Code:
  1. import QtQuick 2.3
  2. import QtQuick.Controls 1.2
  3. import QtQuick.Window 2.0
  4. import QtQuick.Controls.Styles 1.2
  5.  
  6.  
  7. ApplicationWindow {
  8. id: theGui
  9. property int appHeight: theGui.height
  10. objectName: "mainWindow"
  11. visible: true
  12. visibility: "Maximized"
  13. title: qsTr("Map")
  14.  
  15. Repeater {
  16. id: mapRepeater
  17. model: mapModel
  18. Rectangle { width: xSize * model.modelData.scale; height: ySize * model.modelData.scale
  19. color: ((xIndex % 2 == 1 && yIndex % 2 == 0) || (xIndex % 2 == 0 && yIndex % 2 == 1)) && (xIndex < 90) ? "white" : "black"
  20. x: xPos * model.modelData.scale
  21. y: yPos * model.modelData.scale
  22. Text { text: (yIndex == 10 || xIndex == 14) ? "" : "(" + xIndex + ", " + yIndex + ")"
  23. anchors.right: parent.right
  24. anchors.top: parent.top
  25. font.pointSize: 25 * model.modelData.scale
  26. color: (xIndex % 2 == 1 && yIndex % 2 == 0) || (xIndex % 2 == 0 && yIndex % 2 == 1) ? "black" : "white"
  27. }
  28. }
  29. }
  30.  
  31.  
  32. }
  33. }
To copy to clipboard, switch view to plain text mode 

From the rectangle component of the Repeater how would I access the "ApplicationWindow" height (i.e. appHeight). I tried with global variables (Qt.appHeight) but couldn't get that to work.

Essentially I want the rectangle to be able to access the dimensions of the ApplicationWindow.

Thanks