Hi everyone, I’m trying to use drawj2d to generate .rmdoc files for the reMarkable tablet, specifically to create sticker-like elements with a white filled shape (like white boxes or white widgets). Everything works except one issue: ❗ Problem Whenever my PNG contains solid white areas (#FFFFFF), drawj2d renders those areas as either: completely transparent or extremely faint / washed-out even when the PNG has no transparency (alpha channel fully removed). Grey or dark lines render correctly. Only...
**How to make solid white PNG areas render correctly in .rmdoc for reMarkable? ** Hi everyone, I’m trying to use drawj2d to generate .rmdoc files for the reMarkable tablet, specifically to create sticker-like elements with a white filled shape (like white boxes or white widgets). Everything works except one issue: ❗ Problem Whenever my PNG contains solid white areas (#FFFFFF), drawj2d renders those areas as either: completely transparent or extremely faint / washed-out even when the PNG has no transparency...
Hi, and thank you very much for maintaining Drawj2d — it’s an amazing tool. I'm working on creating sticker-like elements for the reMarkable tablet (RMPP / RM2), and I'm running into a behavior I'm unable to explain or solve. The issue: PNG images rendered via image always appear transparent on the reMarkable. Even when I: remove the alpha channel completely, place a solid white background behind the artwork, export the PNG at high resolution, or use pen white, pen black, or any supported color,...
This is very interesting. I have been experimenting there and have failed so far in most respects but found other things that worked. I'll include more details but I'll move it to the 1.4.x discussions.
Hello, This is in reference to pens a colors and your previous reply https://sourceforge.net/p/drawj2d/discussion/general/thread/14a98d3bc3/#86bf/dac6 I have been experimenting with the code in https://sourceforge.net/p/drawj2d/code/HEAD/tree/trunk/src/net/sf/jtikz/ReMarkablePage.java Specifically, I attempted to use colors higher than 13, but failed with any of the eight pens I tried. However, with the colors 0 - 13, all of the eight pens worked with all of the colors. In particular, the highlighter...
I want to convert a png to rmn, however when running: echo image .\test.png | .\drawj2d -Trmn -o test.rmn or echo image test.png | .\drawj2d -Trmn -o test.rmn or echo image "test.png"| .\drawj2d -Trmn -o test.rmn I get following exception: Mode: JTikZ Hecl exception: {ERROR {Missing filename}} {image 1} Error occurred. Check for error messages. Any Idea what the Error wants to tell me ? The image is directly next to drawj2d . I dont get what filename should be missing. Cheers
Does this work on 'M' chip macbooks? I attempted to download after installing Java and received an error message 'Check Console for possible error messages related to "/Users/xxx'Drawj2d/drawj2d.jar.'? I am a non as familar with command lines and terminals, but have been able to do jailbreak devices in the past.
Drawj2d 1.4.0 released
Drawj2d 1.4.0 released
Please use this forum topic for comments about these releases.
Tagging the release 1.4.0
resources/ Adapt to version 1.4.0
doc/,resources/ Adapt doc to version 1.4.0
call command textappend (not textcontinue)
The command will be called textappend (not textcontinue).
The second vote goes to the "info label width" to get the width before writing. That would be useful for detecting column width in tables. The next release of drawj2d will introduce the command info: font Lines bold 5 pen 0.3 m 10 10 set txt {underlined bold text} set width_mm [info label.width $txt] label $txt BL mr [mm 0 1] linerel [mm $width_mm 0]
The second vote goes to the "info label width" to get the width before writing. That would be useful for detecting column width in tables. The next release of drawj2d will introduce the command info: font Lines bold 5 pen 0.3 m 10 10 set txt {underlined bold text} set width_mm [info label.width $txt] label $txt BL mr [mm 0 1] linerel [mm $width_mm 0]
add info command
font type "Lines" bold: increase stroke width
So if there was a way to control the thickness of the lines in those fonts, maybe as a scale factor. That would be great. The next release of drawj2d will introduce a new font style pen for Lines / LinesMono fonts. It is equivalent to the plain (upright) style, but the thickness of the lines is taken from the pen stroke width (at the moment the font is changed to Lines). Example: pen 0.55 font Lines pen text {really bold text}
new style "pen" for Lines font
remove --type rmapi
add textcontinue command (justify)
The next release of drawj2d will introduce a command textcontinue (or just textc). It will append text to the previous paragraph written by the text command (or an earlier textcontinue command, but not to labels). Example input m 5 10 font {Libertinus Serif} text {Drawj2d creates } justify font Lines bold textcontinue {technical line drawings} font {Libertinus Serif} plain textcontinue { in vector format (pdf, svg, ...). The command line program reads a text file that describes the drawing. The input...
The next release of drawj2d will introduce a command textcontinue (or just textc). It will append text to the previous paragraph written by the text command (or an earlier textcontinue command, but not to labels). Example input m 5 10 font {Libertinus Serif} text {Drawj2d creates } justify font Lines bold textcontinue {technical line drawings} font {Libertinus Serif} plain textcontinue { in vector format (pdf, svg, ...). The command line program reads a text file that describes the drawing. The input...
add textcontinue command
Not sure which issue you are referring to. To run drawj2d cd into the directory where you have unzipped drawj2d files and then run drawj2d -Tscreen doc/example.hcl On the command line you should see a few lines ... Welcome to Drawj2d Copyright (c) A. Vontobel, 2014-2024 Version 1.3.4 Mode: JRE Preview: doc/example.hcl ... and a windows should open showing the same content as in doc/out-example.pdf. Hitting the Esc key closes the preview window.
Thanks for the information. Drawj2d still uses "reMarkable .lines file, version=5" . This might (or might not) be an issue for the shader colours. For the record: The relevant drawj2d code is in these two files - net/sf/jtikz/ReMarkablePage.java: rmColour and rmPen - net/sf/jtikz/RemarkableGraphics2D.java: linecolour() For testing purposes it should be enough to adapt, compile and run the single file net/sf/jtikz/ReMarkablePage.java. It has no dependencies other than the java runtime. The main()...
I think the shader colors have been identified, e.g., https://github.com/ricklupton/rmscene/blob/997f0b4769dbce0c5f49c53feb439123c294a1f5/src/rmscene/scene_items.py#L96 https://github.com/ricklupton/rmscene/pull/44/files I have not been successful attempting to use those colors. I'm not trying to change your code, I'm simply doing a (simple-minded) edit of an .rm file (i.e., changing black '0000' to shader red '0018'. I'm aware that I'm out of my depth here, so I'm sure this is too simplistic an...
Long shot, but did you manage to find a solution to this? Having exactly the same issue.
I cannot get the command line to output anything have installed jre, but can't get any sort of response from the command line.
enhance dxf support (entity face3d)
When it come to the fonts Lines and LinesMono, I know about the plain vs bold style. The thing is that they have, in my opinion, too thin lines compared the there size when using the plain style, especially when displayed on the reMarkable. So I usually always use them bold. What I would like to implement in the markdown conversion tool, is the different levels of bold that some Markdown viewer shows . So if there was a way to control the thickness of the lines in those fonts, maybe as a scale factor....
When it come to the fonts Lines and LinesMono, I know about the plain vs bold style. The thing is that they have, in my opinion, too thin lines compared the there size when using the plain style, especially when displayed on the reMarkable. So I usually always use them bold. What I would like to implement in the markdown conversion tool, is the different levels of bold that some Markdown viewer shows (see attachment). So if there was a way to control the thickness of the lines in those fonts, maybe...
font Lines bold and font LinesMono bold should work: I'll have to explain the parameters for label in the manual. BL (base line) and BLC (base line continue) are indeed hard to guess... It would be really nice to have a tool to interpret markdown or at least a subset of it. The implementation for text is quite rudimentary. A few ideas: - Maybe we would need a command "append text (write)" that just continues writing (knowing xLeft, text coloumn width and the current position) but does line breaks....
font Lines bold and font LinesMono bold should work: I'll have to explain the parameters for label in the manual. BL (base line) and BLC (base line continue) are indeed hard to guess... It would be really nice to have a tool to interpret markdown or at least a subset of it. The implementation for text is quite rudimentary. A few ideas: - Maybe we would need a command "append text (write)" that just continues writing (knowing xLeft, text coloumn width and the current position) but does line breaks....
You are right, I want to change font and/or properties of some words in the middle of text block even if it is split up into multiple lines. A short time after I published my quetstion, I realized that it might not solve what I wanted to do anyway. Since I like to use the "Lines" and "LinesMono" fonts, and as I understand, the line thickness of these cannot be changed to make them bold. I did not know about BLC, I have only been using the compass directions since they where the only one I could guess...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Currently drawj2d does not remember where the last writing operation ended. That could be implemented (in net/sf/drawj2d/cmd/API.java ) for the commands label, texlabel and text. A new command textpos could return that position. May I ask what the intention is? Do you want to change the font properties (e.g. bold)? Then we might need to remember the x position "here before text" as well, for the carriage return ... For a short text without line breaks you can use the BLC (base line continue) parameter...
Would it be possible to add a new function similar to here, that instead of returning the current position, returns the lower right bounary position of the last text line? Perhaps call it textpos.
Would it be possible to add a new function similar to here, that instead of returning the current position, returns the lower right bounary position of the last text? Perhaps call it textpos.
Would it be possible to add a new function similar to here, that instead of returning the current position, returns the lower right bounary position of the last text? Perhaps call it textpos.
Thanks for your contribution! (Sorry for the delay. The message was erroneously classified as spam.)
I've just figured out how i can plot any mathematical function into an rmdoc notebook in high quality and colour in a few steps! I mostly combined various tips from the forum and the wiki and tinkered around my self a bit. Plot your stuff: visit geogebra.org https://www.geogebra.org/graphing to plot whatever you want Polish for export: enable or disable grid as you prefer (rightclick on background) etc. adapt the colors of the graphs to the values mentioned here under "Pen colours": Drawj2d Discussion...
This is how I solved filling shapes (not limited to circles though) with hatches - and yes I know, it draws quite some lines..... Tried to increase the pen width to limit the number of strokes, however I could not find a generic solution that filled the entire shape. proc fill.circle {x y radius fcolor} { if {= [strcmp $fcolor none] 0} {} else { set prevpen [pen $fcolor solid] hatch 45 [expr 0.75*[lindex $prevpen 2]] hatchcircle $x $y $radius pen $prevpen } circle $x $y $radius } As my contribution...
My use case is multiple 1. I use layers on the reMarkable to selectively hide/show my markings - used to memorize and practice exercises while keeping at the same time a sort of 'version history'. When Drawj2d supports multiple layers, I can create in the same document both the exercise AND the solution. 2. I use layers on the remarkable to differentiate between how "sure" I am of my markings: draft - final - thoughts etc. When Drawj2d supports multiple layers I can create a layer with shapes (the...
I am not sure if it is even possible to implement. To my knowledge the rm lines format (version 5) does not support groups directly. It has lines consisting of multiple segments. If a shape is drawn with a single line it gets selected like an object. Hatches (for general shapes) cannot be drawn with a single line. Also I am not aware of a "lift pen" attribute for line segments. Thus I would not know how to create a single object for hatches. By the way. It would be an interesting task to develop...
Drawj2d does not support drawing on different layers. I guess it would actually require too much work to implement (for a feature I do not use personally). May I ask what is your use case?
You are welcome
Thank you so much for you super-fast response. With the example you gave above, I now do understand the geom.topolyline commands and what their use case is. For other shapes that needed to be selected as one, I already used the polygon command, but could not figure out how to include curves in it. That is now solved. Again, many thanks. Keep up the good work. John
Hi, Is there support of the 'layers' in rmn/rmdoc files? I'd like to have shapes on different layers. If not, is this a future feature. Maybe the Opacity can be used for this. Eg Opacity 1.0 => Layer 1, Opacity [0.9 - 1.0) => Layer 2 etc John
Hi again, I have another observation, where the output behaves in a different way than I expected. While circle, rectangle and polygon result in one single object on the reMarkable, the hatch-variants generate multiple objects: each stroke of the hatch is a separate object. This has been discovered while I was searching for a workaround because the reMarkable does not support the fill property. Can you please advice? Thanks in advance. John
Your observation is correct: The block/endblock commands do not put the line segments into an object that can only be selected as a whole (as a block) on the reMarkable. Drawj2d actually just draws subsequent line segments. As a work-around to get a single object you can use the polygon command. font Lines set A " 5 5" set B "30 10" set C "20 40" m 20 20 block line $A $B $C $A label {Line segments are selectable} endblock m 20 70 block polygon $A $B $C label {Polygon is selectable} endblock The command...
Hi, Just stumbled upon Drawj2d and I absolutely L-O-V-E it thank you so much!! My prime use case is to create rmdoc to be used on the reMarkable tablet. I thought that the block/endblock command would not only prove a frame with its own coordinate system, but that it ALSO would ensure that the drawings command inside the block/endblock are considered as one. Meaning that the selection function on the reMarkable would not consider the individual drawing commands yet all or nothing. I created a block/endblock...
Awesome! That's exactly what I was looking for. I will work with png as the svg conversion doesn't seem to handle the fill parameter. Thank you!
Examples_reMarkable_ShapesLib
Examples_reMarkable_ShapesLib
Examples_reMarkable_ShapesLib
Thanks, your welcome. I often work with old scanned drawings. These are always black lines on white background. This is the main reason I implemented an algorithm to convert raster images to a rM line representation. It's also the reason I did not care much about colours (it would have been grey only next to black and white at that rM2 time anyway). Is there an option or method to preserve colors or choose a specific color (like white) when converting PNG or SVG images to rmdoc? When converting PNG...
Hi! First, I'd like to express my heartfelt thanks to the creator of Drawj2d for this fantastic tool that has truly opened up new horizons for me with my reMarkable Paper Pro . Thanks to this program, I've been able to add images to my notebooks and create really cool custom covers. It's a real asset for my daily use of the RMPP! However, I have a question regarding image conversion. I've noticed that all the images I convert to rmdoc format appear in black. I would like to be able to convert transparent...
reMarkable
The supported pen colours for notebooks with colours on the rMpro are listed above. In the hcl file you can use them like this: font Lines m 15 10 pen blue text {Some text in blue.} pen red linerel 50 0; # a red line If you just convert a pdf (or svg) to a notebook using the following command on the command line: echo image my.pdf | drawj2d -Trmdoc then the colours are only applied if they match exactly the supported colour definition. Use the exact red-green-blue (rgb) values for the colours when...
The supported pen colours for notebooks with colours on the rMpro are listed above. In the hcl file you can use them like this: font Lines m 15 10 pen blue text {Some text in blue.} pen red linerel 50 0; # a red line If you just convert a pdf (or svg) to a notebook using the following command on the command line: echo image my.pdf | drawj2d -Trmdoc then the colours are only applied if they match exactly the supported colour definition. Use the exact red-green-blue (rgb) values for the colours when...
The supported pen colours for notebooks with colours on the rMpro are listed above. In the hcl file you can use them like this: font Lines m 15 10 pen blue text {Some text in blue.} pen red linerel 50 0; # a red line If you just convert a pdf (or svg) to a notebook using the following command on the command line: echo image my.pdf | drawj2d -Trmdoc then the colours are only applied if they match exactly the supported colour definition. Use the exact red-green-blue (rgb) values for the colours when...
Forgot to mention in the release notes: --deprecate --type rmapi (will be removed) rMAPI supports - rm - rmdoc (since version 0.2.7) Thus the old output type (zip file with old style metadata) is not needed anymore. Due to a recent rM cloud API change you will need an up to date version of rmapi.
On my rM2 (3.14.1.9) it is black indeed. On the rmPro (3.14.3.0) it is gray. Let's see if an update (to the rM2) software will fix it. The lightgray is quite special. Even when using the fineliner (as drawj2d does) it gets darker when overlapping. Thanks for reporting, it is useful! I have not yet digged deep to find out how colours work. Orange is missing, there is a second black colour (no. 9). Also I don't know about the shader pen (not really needed for drawj2d) ..
Please recheck lightgray. It is giving me black.
Or ... it occurs to me that maybe it's because I'm on a RM2? Just a guess. (Re: lightgray)
Announcement on Reddit Geometric shapes in rM notebooks - Drawj2d updated to support reMarkable Pro colours Drawj2d is a tool to create technical line drawings in vector format (pdf, svg, ...). It can also write reMarkable notebook pages (rmdoc / rmn / rm). These notebooks are editable on the tablet, thus select/copy/paste works. The command line program reads a text file that describes the drawing. The input language consists of commands such as line or label. Coordinates are given in natural units,...
Drawj2d 1.3.4 released
Tagging the release 1.3.4
resources/ enhance wiki for reMarkable Pro
reMarkable
reMarkable
reMarkable
reMarkable
doc/,resources/ Adapt doc to version 1.3.4
reMarkable
add doubleline command
enhance rm output: image command uses pen colour (png+svg)
deprecate --type rmapi
enhance rm output: more colours
Release 1.3.4 will add more colours for the reMarkable (-T rm / rmdoc / rmn). You can already test it if you download the source code and compile it. Requires JavaSDK (compiler) and ant.
enhance rm output: more colours
Glad it works.
Oops, I'm sorry, my fault... I didn't execute the command correctly. It does works as intended, except for rmapi which I knew didn't work. That was why I tried the other formats. Thanks for a super tool!
Strange. While I have issues using rm2/rmPro in parallel (see below) I currently cannot reproduce the issue you describe. Do I understand correctly: drawj2d still creates these notebook files (e.g. rmdoc) but you cannot transfer them to the device anymore? Could you please collect some information: device type: rm2 or rmPro? drawj2d version (current is 1.3.3) device software version? how do you try to upload rmdoc? desktop app or USB web interface? error message? Observations? anything else that...