I am trying to represent a gameboard for a user to interact with. It needs to be a 9x9 Grid which they can move the two to three different player pieces around and send signals to the main game object with the new position after a move. The game object would give coordinates for where to draw pieces on the board. I was originally planning on using QGraphicsView to represent the board but it is beginning to look a lot more complicated then it needs to be for the board representation. I found a post here on how to http://stackoverflow.com/questions/1...g-and-dropping represent a grid but it seems difficult to set a specific grid size, keep the grid in the users view, and add nice graphics to it. After looking online it seems alot of people who write similar programs are using QML and the GridView to represent their boards. What would be the most recommended route for constructing the game board, allowing users to manipulate pieces etc. Also if I do use QML is there an easy way to add it into my QMainWindow derived window or will I have to design the whole window and not just the board element in QML. This is my first QT project so I am sorry if I am asking an overly basic question here. Also would I be able to handle all the QML logic with C++ or would I have to incorporate JS as well?
Bookmarks