Drag and drop markers

Question types ::: qtype_ddmarker
Maintained by TimTim Hunt, Jamie Pratt, Phil Butcher
Part of set Open University.
The student can drag markers to indicate key features on an image.
Latest release:
50 sites
44 downloads
24 fans
Current versions available: 6

There are working examples in eAssessment with Moodle on our OpenLearn site.

The documentation is in How to create questions in Moodle on that site.

Screenshots

Screenshot #0

Contributors

Tim
Tim Hunt (Lead maintainer)
Jamie Pratt: Developer
Phil Butcher: Question type designer
Colin Chambers: Developer
Please login to view contributors details and/or to contact them

Comments RSS

Comments

  • not cusack
    Mon, 20 Feb 2012, 6:43 PM
    How do I set the markers without knowing the coordinates and size of the marker text? I can't seem to just drag the created text rectangles onto the image like I can with drag and drop onto an image for some reason...?
  • Tzvi Daum
    Fri, 30 Mar 2012, 12:26 PM
    Here is a video tutorial I created for this question type including how to find and define the appropriate coordinates.

  • Ralf Hilgenstock
    Fri, 23 Nov 2012, 7:17 PM
    It looks taht there is a wrong placeholder in lang fliel string
    $string['addmoreitems'] = 'Blanks for {no} more markers';
  • Tim
    Fri, 23 Nov 2012, 7:36 PM
    Why do you think that is wrong? It is supposed to be like that. There are similar strings in other qtypes like multichoice, and repeat_elements in formslib.php expects the string to be of that form.
  • June 2007
    Wed, 13 Feb 2013, 3:27 PM
    This question type seems to resize the uploaded images, and does a very poor job at it. I uploaded a 600x630px diagram. When displayed, it appears at a very poor quality 380x400px resolution... Am I doing something wrong? I've tried jpg and png as source files, but it makes no difference to the output.
  • Jamie Pratt
    Wed, 13 Feb 2013, 3:36 PM
    See the top of ddmarker/questiontype.php you can change the max width and heights there. They are set as follows :

    define('QTYPE_DDMARKER_BGIMAGE_MAXWIDTH', 600);
    define('QTYPE_DDMARKER_BGIMAGE_MAXHEIGHT', 400);
  • Phil Butcher
    Wed, 13 Feb 2013, 10:42 PM
    Those sizes are just the OU defaults. We deliberately have a maximum size for images. For our main online documents the size is actually smaller (500px wide). And the reason is to ensure that our stuff looks good and works on the maximum number of devices. As Jamie indicates if your need is different then just change the max width and height.
  • Paul Nijbakker
    Fri, 22 Feb 2013, 4:23 PM
    Hi, We encountered an issue with the infinite marker. If you work with infinite markers students just have to drop the marker on all spots in order to get a full score. They do not get a penalty for dropping wrong markers (as long as they also drop the correct marker). Also a user can drop an infinite marker countless time in the same spot without penalty. In Tvi's video, if both the circle and rectangle markers are infinite, a user could drop the circle marker on all spots and the rectangle marker on all spots and get a perfect score. Even if penalties are included, a user could drop the circle marker ten times on each circle and get a perfect score, so the question is not suitable for tasks where there should be a limit of the amount of infinite markers that can be dropped on any spot. Am I right?
  • Phil Butcher
    Fri, 22 Feb 2013, 5:50 PM
    Your analysis is correct, but also not something I've encountered - i.e. students being 'clever' in this way. As such I didn't plan around it. I shall ponder what to do. All sensible ideas welcome.
  • philippe dutour
    Sun, 17 Mar 2013, 4:37 AM
    Hello,
    I'd like to change the viewfinder (target) arrow (perhaps replacing the file 'crosshairs.png'.
    I would also like to orient differently and with a variable position around the label position on the image.
    Or is it just that I find these settings in the PHP files?
    Thank you.
  • Tim
    Mon, 18 Mar 2013, 3:28 PM
    I think the position of the marker image relative to the key pixel is achieved with CSS: https://github.com/moodleou/moodle-qtype_ddmarker/blob/master/styles.css#L83. That means that the key pixel is at position (7px, 7px) in the crosshairs. I think that at the moment, the position of the label next to the marker is also done with CSS. That is easy because the label comes after the cross-hairs.

    You can change all this, but you will have to edit the code.
  • philippe dutour
    Tue, 19 Mar 2013, 4:20 AM
    Thank you for your help,
    I spotted these points, after your advice I have edited and saved the file on my site 'styles.css' I've changed' - 7 in 20 px then 50 then 100. I then (each) recreated exercises, and nothing changes .....
    What have I missed in my approach?
  • Tim
    Tue, 19 Mar 2013, 2:29 PM
    Have you got Theme designer mode turned on? If not, you will have to keep purging caches to see the CSS changes.
  • philippe dutour
    Wed, 20 Mar 2013, 4:40 AM
    I do not understand what to do ...
    I open the folder of my site 'techphil.fr / question / type / ddmarker, then I open the file' styles.css' I change settings online 83 records and I am trying ... without success. Where is it 'Theme designer ....' What have I missed. It is obvious that I do not control this, if a little more information is possible, it would be with great pleasure. Photo of the open page of my site with files ddmarker.
    I try to clear the cache in Moodle 'it works' I have many ... mofifs;
    But when I try a question and I ask to give me the answer, the answer seems to me that what is considered 'good' is always there and x-7 -7 px..
    Thank you
Please login to post comments