Auto generate qr codes with variable data

Asked by Marcio Shibata

Hi guys,

First of all thank you for thiw wonderfull software Inkscape.

I'm creating visiting cards with Inkscape, but I have the need to insert qr codes in a way that each visiting card has a different qr code. I was wondering if there is a way to automate this process.

Another question: suposing I'm printing in a 2X6 cards sheet, how could I insert crop marks in it?

I don't know if it could help but I'm a very well skilled php programmer.

Thanks a lot.

Question information

Language:
English Edit question
Status:
Solved
For:
Inkscape Edit question
Assignee:
No assignee Edit question
Solved by:
Marcio Shibata
Solved:
Last query:
Last reply:
Revision history for this message
Hachmann (marenhachmann) said :
#1

Hi Marcio,

QR codes:
mmmh... I'm not sure that works without editing the python extension itself, at least not if you want a different code each time.
I think that with php and the commandline interface, it could be possible to script the qr code generation, but you'd have to find a way to feed the variables in without typing them into the dialog.

With the extension as it is now, using the --verb option via cli will only open the dialog. (or apply the functionality to a selected object if there is no dialog for a given extension, or use the last used parameters from the dialog, if 'noprefs' is appended).

If you're adventurous, you could try to edit a copy of the QR Code extension in order to get its parameters from somewhere else (python, though, not php).

I never tried anything like this myself, so I can't help further.
Man page: https://inkscape.org/fr/doc/inkscape-man.html

Crop marks:
What kind?... Is Extensions -> Render -> Layout -> Printing marks okay? With .noprefs it could work (set this once inside the program). Or you just make a template that you use as a basis everytime, and save it under a different name each time you use it. I guess the crop marks will be at the same place in each file ;)

Good luck!

Regards,
 Maren

Revision history for this message
Marcio Shibata (extra-5) said :
#2

Dear Maren,

I guess this time it will be faster to just generate all the cards (including crop marks) with php, I found a great lib that generates qr code (http://phpqrcode.sourceforge.net/), with minimal modifications I think it can do the job.

Anyway thanks a lot for your reply.

Best regards,

Marcio

Revision history for this message
Hachmann (marenhachmann) said :
#3

Yeah, I thought something like this after I posted my reply, too :) Hope you'll make some nice cards!

Revision history for this message
Marcio Shibata (extra-5) said :
#4

Dear Maren,

You will not believe it, at the end I decided to do the codes one by one in inkscape =P.

As I'm printing just 200 cards it will be faster to do this way.

Thanks anyway for your votes, as soon as finish I can show them if you want.

By the way, if you need any help with php or javascript I"m at your disposal, you can even write to me directly if you want:

<email address hidden>

Best regards,

Marcio