Download source files and place them on to be created "yaqr" folder under the CKeditor's plugin base.
Define plugin in CKEDITOR config object.
CKEDITOR.config.extraPlugins = 'yaqr';
Set your CKEDITOR language if you did not set it yet.
CKEDITOR.config.language = 'en';
You're Done !!
You can define default widget configuration. The default config is :
// // default accepted tags, can be overriden by config file // defaultConfig = { defQrUrl: "https://ckeditor.com/", // Default URL when creating a new QR-Code defTargetBlank: true, // Target Link Mode (if true target = "_blank" else target = "_self") defQRSize: "100px", // QR Image size defCellSize: 6, // Points size for QR-Code defMargin: 10, // Space between QR-Code and Border colorPt: "#000000", // QR Points Color colorBg: "#ffffff", // BackGround Color borderWidth: 2, // Border Width borderColor: "#000000", // Border Color correctionLevel: "Q" // Correction Level (possible values : "L"=Low, "Q"=Quality, "M"=Medium, "H"=High) };
If you like to change a sedault parameter, just insert in your config.js file something like :
config.yaqr = { defQrUrl : "http://devlabnet.eu/index.php", defQRSize: "25%", defCellSize: 8, defMargin: 20, colorPt: "#00FF00", colorBg: "#ff0000", borderColor: "#0000FF" }
This represent the number of pixels used to generate each point of the QR-Code. If you put a low value, the generated image (I mean the "data:image/gif;base64,R0lGODdh2gDaAIAAAP8AAID..." string)
will be small, but the payoff will be that the image resolution is not very good, so if you increase it size, result will be blurry !.
I choosed "6" for default as it' a quite good compromize.
None as today
Currently plugin supports the following languages.
Translations are welcomed.
New version 1.0 (September. 01 2017) has been tested on