moodle-mod_simplecertificate icon indicating copy to clipboard operation
moodle-mod_simplecertificate copied to clipboard

How to resize of QR code to be smaller in simple certificate?

Open williamtekkom opened this issue 6 years ago • 4 comments

qr

williamtekkom avatar Jan 10 '19 01:01 williamtekkom

Only changing the source code.

https://github.com/bozoh/moodle-mod_simplecertificate/blob/master/locallib.php#L1093

$pdf->write2DBarcode($codeurl->out(false), 'QRCODE,M', $this->get_instance()->codex, $this->get_instance()->codey, 50, 50, ....

the 50,50 is the width and height , if the bottom text (code text) get weird, comment this line:

https://github.com/bozoh/moodle-mod_simplecertificate/blob/master/locallib.php#L1097

bozoh avatar Jan 10 '19 15:01 bozoh

Knowing how to resize the QR code is really useful - but I also want to reposition it, so it appears bottom left rather than top left - how do I do this?

davefoord avatar Mar 10 '22 10:03 davefoord

Knowing how to resize the QR code is really useful - but I also want to reposition it, so it appears bottom left rather than top left - how do I do this?

Hi Dave! Did you find how to do it?

Yes - very easy to reposition, the settings are actually within each certificate activity, so you can have some bottom left, some top right, some in the middle etc. Within the certificate settings, and the 'Others Options' there is a 'show more' link at the top of the section, if you click on that, it gives you two boxes to identify the horizontal and vertical positions.

Note, you can also change the default settings at site admin level, for any new certificates.

davefoord avatar Apr 05 '22 07:04 davefoord