I am nearing completion of the PaintWeb drawing application. Code reorganization is done and the new GUI is almost done.
Everyone who is interested, please take the time to test it over at:
I am currently working on the updated color mixer, after which the application is pretty much "done". I can continue working on packaging and Moodle integration. Obviously, further new features and fixes are planned as we go along.
Enjoy! Please let us know if you find any bugs. Thanks!
You are doing a good job on PaintWeb. I was just trying out the demo just a few minutes ago. Here are a few comments:
- Could you add some color to the buttons? Right now some of the buttons have more color than others. This made me think that maybe the other buttons were disabled. The help button was also hard to see in the corner.
- Also when I was using the controls in the eraser, they required me to press 'enter' after I had changed the input. Other buttons didn't require me to press enter, a click was enough.
- Is there a limit to undo? I was playing around drawing some shapes, but could only do a limited number of moves.
- Can the default setting be a white background with a dark think pencil?
Thank you very much for your feedback.
1. Adding colors, hmm ... not sure on this one. I added color only where I considered it's necessary. Should I use some colors for the shapes? For rectangle, ellipse, etc...?
2. The issue with the controls is "simple". I listen only for the input value "change" event. Browsers only fire the event when you press Enter and/or unfocus the input field. I could listen for the "input" even - for every character inserted, but then it would be slower. I'll ask my mentor how he prefers we deal with this issue.
3. Yes, there's a limit to undo: maximum 10 steps. This can be easily configured.
4. Not sure I understand the question... Please elaborate. The image background is white by default. It will be possible, in the future, to change the background color of the image.
Thanks again and good luck with your project as well!
Looks good - really looking 4ward to Moodle integration
Thanks so much
Could you please retest in Safari?
I just updated PaintWeb and now it's all packaged. This might affect how it works in Safari on your Mac.
For more details here's my latest blog post about packaging:
And here's the link to the PaintWeb demo:
Thank you very much for your time!
I loaded up the developer tools in Safari and when the page loads, there are no js errors, when I click on 'Edit Image', I get the following error:
/paintweb/trunk/src/includes/lib.js:171 TypeError: Result of expression 'JSON.parse' [undefined] is not a function.
I hope this helps,
I have tried it with Firefox and Konqueror on PCBSD and no problems.
Apart from the hand tool moving the background and no way of selecting object.
A hearty well done.
Thanks for testing my application.
Could you please explain what do you mean with the hand tool moving the background? It should allow you to drag the image in the viewport, when the image is bigger than the viewport. Nothing more.
Selecting objects is not possible - this is not vector-based drawing, it's bitmapped, like in MS Paint.
Thanks for your appreciation. ;)
I think in that case Safari does not properly fire the "load" event for the json library script, which is weird. Safari 4 on Windows works fine for me. Chromium browser on Linux works fine as well.
I do not have a mac to test things on it...
(thanks for the detailed error report!)
/paintweb/trunk/build/paintweb.js:1 SyntaxError: Unable to parse JSON string . Maybe do a google search or take a look at webkit for existing bugs related to json parsing?
This means that Safari 4 probably does not properly fire the 'load' event for the script. PaintWeb, when initialized, loads the json2.js file, and then goes on to actually use code from that JS. If the browser fires the load event too soon, PaintWeb "crashes" because it makes use of undefined methods.
Safari 4 (Webkit) does not yet implement JSON natively - hence the need to load json2.js. Webkit devs are working on it. ;)
To work around this isssue I think I need to load the json2.js file earlier - before PaintWeb instances are initialized/created, such that I do not need to rely on the 'load' event for the said script.
Thanks for testing again.
Thanks for testing. This might mean my initialization fixes were effective.
The problem you mention with TinyMCE is, indeed, valid. The problem is not related to PaintWeb - in any TinyMCE installation you cannot select images, which is really unfortunate. This issue affects any Webkit-based browser: Google Chrome and Safari mainly.
Given you cannot easily select image elements, you cannot easily get to PaintWeb either.
The only way I found is to use Shift+Arrows. You can go with the cursor right next to the image, then use Shift to select it.
I tested another WYSIWYG editor like TinyMCE. The same problem: you cannot select images. It looks like it's not a TinyMCE bug, but a Webkit bug in the support for editable content.
For those interested in further testing, I have a second PaintWeb demo with TinyMCE 3 integration:
I could not get the colour pallette or mixer to work at all though.
I am using Firefox 3 on Ubuntu 9.10
Thanks for testing.
Please go ahead and test it. The web application should be fully functional. Please let me know if there's something going wrong.
Thanks for your time. ;)
Can we have a browse instead of insert from URL in the insert image. That keeps it consistent with other Moodle editors.
I will work on that during the Moodle integration (which is rapidly approaching). Obviously, I need to use their new File APIs and any of the relevant functionality to make things "just work".
Keep up the good work. I am excited about this additional functionality. Sorry I wasn't able to get students to use it during summer school because we didn't have the right browser.
Don't worry. I really appreciate your interest in this project.
Very nice! Please do keep up the good work.
I'm glad to see people are interested into this project.
I have started work on Moodle integration, which is currently more in the initial planning stages. I hope it won't take too long before a demo can be tested by users.
Thanks for trying PaintWeb and for your kind comments.
Indeed, the issue about how to edit the image and how to finish is quite confusing. However, fear not: the solution is already implemented on my system, I just need to push the update to the demo on the robodesign.ro server. (i'll do this asap)
I'm done, hehe. You can try the updated TinyMCE plugin:
Not too much on the visible side, but you now have obvious "save" and "cancel" buttons, with proper feedback.
The code evolved quite a lot, now PaintWeb is dynamically unloaded, when it's closed, and there's complete support for server-side file save, there just needs to be a PHP script to handle the save.
I have also made some API changes/improvements for proper localization and file saving support. The updated API reference reflects the changes. I'll also update the documentation at Google Code, when I have time.
Please let me know if you have more suggestions.
The presentation can be downloaded from:
Or, if you prefer, you can watch it online:
In these slides I describe the work I did on my Google Summer of Code project.
Any feedback is welcome.
Thank you for sharing your presentation. It was very interesting getting a peek at what went into this kind of project and some of the parameters you had to work in.
Thank you also for your hard work and continued work on developing this tool.
The Moodle 1.9 code is ready. However, it uses a new database table for tracking images saved by the paint tool.
The code for automatic installation of the new table is not yet merged into the my Git repository that holds the paint tool integration into Moodle 1.9.
I have to ping Martin Langhoff about this.
Please let me us know when it is ready for download here. Looking forward to trying this out.
I'm testing your patch in order to include TinyMCE & Paintweb in the moodle production site of ULPGC.
I have managed to wonder the creation of "paintweb-images" directory within moodledata. After error mesages I created a new paintweb-images table with fields id, rid, tbl, col, img and kicked out all error messages claiming for that table.
However, I cannot SAVE images. I always get the error message 'moodle:jsonParseFailed' :
Parsing the JSON result from the server failed!
I cannot see wheer this error is generated. Can you help??
Congrats for your work. It's really lots of work to get it working without any pre-made patches.
I have attached a SQL dump of the mdl_paintweb_images table structure. You can use it to properly setup the table.
Please use the Firebug extension in Firefox to determine which XmlHttpRequest failed, point me to which file failed. With this extension you can see all the info, including the response from the server.
Hence, please check with Firebug what happens more precisely. Please reply with any info you found. Once I get the details I asked for, I am sure we can get to the bottom of the problem.
Dear Mihai Sucan
Hi, I check the link which you provide.It is perfectly working.I want to install PaintWb on Moodle 2.7. Please tell me steps how paint web install in Moodle 2.7.