Important: Please read the Qt Code of Conduct -

MIT Scratch - Vex Clone

  • I am working with a team of people who are making somewhat of a clone of MIT's Scratch. It is a clone in the sence of the blocks and their general functions, but it will be used as a tool to teach students how to program with Vex robotics. It is essentially "this": Our version however will be targeted at the somewhat older version of Vex Cortex instead od Vex IQ. The basic idea is that a user will drag and drop scratch blocks together to generate the c/c++ file to run on the Vex Cortex.

    I am the lead programmer and somewhat new to qt. I am at the stage of writing the module that will house the nested blocks. I thought to use a simple QGraphicsView to do this. If any of you have used scatch, you know that when you nest blocks together, other blocks around it usually expand or change shape to fit the new nested block. The block images are designed in the Scratch software to have certain sections of the image repeated to increase the various dimensions.

    For example, taking a look at the example blocks on , you can see that the blocks have small borders that are expanded to fit the inner block.

    (Please let me know if I need to explain that more)

    I was wondering if anyone had an idea of how to efficiently accomplishing this in a QGraphicsView. My idea to to have an image of the repeatealbe parts and create copies of them depending on how much the block needs to be expanded. I am wondering if someone has a better solution to this rendering task.

    Again, please let me know if I need to change/elaborate more on anything that I have said.

    [edit: corrected the link SGaist]

Log in to reply