Plugin: js-draw integration

The Android beta has been updated again! A "Format Selection" button has been added β€” it is now possible to change the color of selected strokes/text.

Excellent news, and working fine!

Is there any user manual on how to I get the Editor installed on Android with Joplin? I don't see "Plugins" in the Settings of the Joplin App.

@taubers you need to install the latest prerelease. It then appears as 'Joplin beta' aside your normal Joplin, and decorrelated from your normal notes (indeed you get another notespace with the startup notes, how-to etc.)
Within this Joplin beta you have the draw editor exactly like in the current computer version.
I expect the mainstream Android version to incorporate js-draw quite soon now, but if you are in a hurry you may try sync'ing the Joplin-beta instance with your 'normal' Joplin, I suppose you then will get all your former notes duplicated in the beta app (and all the initial beta how-to back in Joplin, unles you deleted them). For this last point I just expect it'll work like that, I didn't try it.
To get the Joplin beta app climb up the thread, you get the apk url in the latest posts from Henry Heino. Download the apk then install it...

I've just released a new version of the Android beta! It adds:

  • The ability to change the background color of an image
  • An "Edit" button that appears after tapping on an editable SVG image.
    • Previously, it was necessary to long-press on drawings, then click "Open" to edit them.

It can be installed (on Android) by downloading the joplin-drawing.apk file in the corresponding GitHub release:

As mentioned above, this beta release installs alongside the stable version of Joplin as Joplin (Beta). It's based on the (work-in-progress) pull request adding the image editor to Joplin. It does not auto-update.

A drawing can be added by clicking "Attach", then "Draw Picture" after opening a note. An existing drawing can be edited by long-pressing and selecting "Open", or tapping once on the drawing and clicking the pop-up "Edit" button.

The Android beta is still a work-in progress. Please let me know if you have any feedback!

Thanks!

Thanks! Downloaded from the link and "attached" and it works very well! Thank you very much!

@personalizedrefriger have you considered applying for Github Sponsors?

I don't plan on signing up for GitHub sponsors, but if you want to support js-draw development, consider donating to one of these organizations:

  • [Accepting donations through GitHub sponsors] bezier-js: JS-Draw uses this library to do much of its stroke-related math (e.g. determining when something intersects a stroke).
  • [Accepting donations through GitHub sponsors] Joplin Organization: I might be working here in a few months, so donations to Joplin should also help js-draw!

js-draw also has a long list of build-time dependencies (e.g. webpack). Many of these are accepting donations, too.

Sorry for the long delay! This should be fixed in version 1.4.7 of the plugin. The plugin now quickly switches to the markdown editor and back again when attempting to insert an image if in the rich text editor.

There's still no way to edit an existing image from the rich text editor, but I plan try to add this functionality soon!

The Android beta has been updated!

Among other changes, new images now have a default background color. After editing an image, the default background color is changed to the background color of the just-edited image.

The Android beta has been updated!

This adds support for grid-patterned backgrounds and merges recent changes from joplin/dev.

Thank you for all this work!!
A side question: do I understand correctly that if I sync the be ta version with my "nominal" server, I'Il replicate my current database to the beta Joplin?
(rather than e.g. propagating the beta emptiness rearwards?)
Thank you again and all the best !

Yes. That should work!

Excuse me, When can I use this function in the official app?

While you can currently use this feature as a plugin in the desktop app, it might take a few months before it's added to the mobile app.

I've been busy with school/work for the past few months, but I should (hopefully!) have more time to work on this in a few weeks.

There are a few things that I would like to do before js-draw is integrated into the full Joplin app:

  • The js-draw UI can be improved. Currently,
    • some icons have color and others don't
    • there's no icon for the "edit" button that appears when hovering over an image
    • I don't like the UI for switching pen types. I think something with icons for different pen types would be better.
    • There's currently no way to duplicate js-draw drawings on the mobile app. (I'm not sure where this functionality should be exposed, though)
  • Stroke smoothing (fitting strokes to BΓ©zier splines) should be improved. It's currently done with hueristics. I've been thinking about trying this algorithm for smoothing strokes, but haven't done so yet.

I was wondering, how does this work with joplin encryption enabled? Would this be something that's encrypted?

Drawings produced by js-draw are stored as Joplin resources. As a part of end-to-end-encryption, resources are encrypted when uploaded to a sync target.

Note, however, that Joplin's end-to-end encryption is not local encryption. Thus, like other data, drawings created using this plugin are encrypted when uploaded to a server, but not encrypted locally (unless done so by the operating system or some other software).

The Android beta has been updated!

I now have more time to work on the pull request, so hopefully the relevant pull request will be ready to be merged soon!

Thank you very much for this Desktop Plugin and Android version Integration. Are you looking forward to integrating it in iOS version?