You need to use EasyEDA editor to create some projects before publishing
Extra rectangle is added with SVG export
549 3
mvandorp 2 years ago
Hi, I own a 3D printer with exchangable toolheads, so I can use the device as a CNC printer or laser cutter/engraver as well. For the laser cutter, I need a SVG file for the input. I was doing this trick to make a nice front panel for my project. As I cannot find a way to add custom layers, I decided to use two otherwise unused existing layers in the PCB layiout. So I designated the "Mechanical" layer in my design for the holes in the front panel. (The "Holes"  layer has all the holes, and that is too much holes!) The "ComponentShapeLayer" was designated for the text on the front panel. I then placed the needed holes (a square for a display, some circles for LEDs) on the "Mechanical" layer, and the needed text on the "ComponentShapeLayer" layer. So far, so good. Then the exports. Because the order matters, I needed three exports: I exported only the "ComponentShapeLayer" to get the texts (which are to be engraved). I noticed I only got a file with the text parts, but without any reference to to board size! I solved this by putting some '+' signe on the outer corners of my board (Same on the mechanical layer). This gives me what I want, with one extra: There is an additional square around everything! It appears to be the ' papersize'. I exported only the "Mechanical" layer as well (to be cut), andf this one also has the additional rectangle! Finally I exported only the 'BoardOutline' layer (to cut my final front panel to size), and this one too has the extra rectangle, a little bit larger than the Board Outline itself. All three resulting files have the identical rectangle around them (thanks to the "+" signs in every corner on every exported layer) The problem of the extra rectangle (it is outside the front panel), is when the cutting starts. My 'job' has three stages: 1) Engrave the text (and the rectangle, but that is no problem here) 2) Cut the holes for the display and the LEDs. The rectangle now becomes a problem, because it cuts loose the front panel from the material. No big deal if this was the last thing drawn, but it is the first one! If it was the last thing drawn, I didn't need the third stage. 3) Cut the front panel from the material. The rectangle causes same problem as mentioned in 2) I "solved"  the problem by opening the svg-files in a text editor and deleted the rectangle definition at the start of the last line (the only one in each file). This gives me a file without the outer rectangle. The engraving and cutting now works exactly as intended. The final result (after a few attempts) is really better then I expected! I tried to edit the svg files with LibreOffice Draw (text missing!) or Inkscape (resulting in a huge file with errors during laser engraving), but the simple text editing was the cleanes way to get what I needed. Is there a way to avoid the generation of this extra rectangle (as the paper size or bounding box or whatever it represents?) in the exported svg? And if so: how do I do this? Any tips and insights are greatly appreciated, Marcel
Comments
andyfierman 2 years ago
Please post screenshots to clarify the issue. Posting your svg files to somewhere like Dropbox would help Support see exactly what you are describing.
Reply
mvandorp 2 years ago
The EasyEDA "Mechanical" layer looks like this: ![image.png](//image.easyeda.com/pullimage/elxlwOM7tHAd5yRPUuAUgEIhb0zWv4LgFCPgu3wV.png) I export this like like this: ![image.png](//image.easyeda.com/pullimage/xZMp2wecx1c85MeDYtOsOor42iUZevsvIAs7hyHE.png) An SVG file is just an XML-file. Just after the style info, I have the following line. The bold part is the part I need to delete. **`<rect x="3679.5" y="2667.5" width="641" height="665" fill="#FFFFFF" stroke="none"/>`**`<g c_partid="part_pcbtext" c_etype="pinpart" c_origin="4304,2684.5" c_rotation="0" c_mirror="0" id="gge4492" locked="0" layerid="15" c_shapetype="group" ><path c_fontsize="8" c_fontfamily="" c_text="+" d="M 4307.27 2677.52 L 4307.27 2684.06 M 4304 2680.79 L 4310.55 2680.79" fill="none"  stroke-width="0.8"  /></g><g c_partid="part_pcbtext" c_etype="pinpart" c_origin="3689.5,2684.5" c_rotation="0" c_mirror="0" id="gge4504" locked="0" layerid="15" c_shapetype="group" ><path c_fontsize="8" c_fontfamily="" c_text="+" d="M 3692.77 2677.52 L 3692.77 2684.06 M 3689.5 2680.79 L 3696.05 2680.79" fill="none"  stroke-width="0.8"  /></g><g c_partid="part_pcbtext" c_etype="pinpart" c_origin="3689.5,3323" c_rotation="0" c_mirror="0" id="gge4516" locked="0" layerid="15" c_shapetype="group" ><path c_fontsize="8" c_fontfamily="" c_text="+" d="M 3692.77 3316.02 L 3692.77 3322.56 M 3689.5 3319.29 L 3696.05 3319.29" fill="none"  stroke-width="0.8"  /></g><g c_partid="part_pcbtext" c_etype="pinpart" c_origin="4304,3323" c_rotation="0" c_mirror="0" id="gge4528" locked="0" layerid="15" c_shapetype="group" ><path c_fontsize="8" c_fontfamily="" c_text="+" d="M 4307.27 3316.02 L 4307.27 3322.56 M 4304 3319.29 L 4310.55 3319.29" fill="none"  stroke-width="0.8"  /></g><rect x="3940.5" y="2842" width="110.236" height="78.74" stroke-width="1" fill="none" c_etype="" transform="" layerid="15" id="gge2018" locked="0" c_shapetype="line" net="" stroke-linejoin="round"/><rect x="3956.693" y="3253.937" width="86.614" height="11.811" stroke-width="1" fill="none" c_etype="" transform="" layerid="15" id="gge2019" locked="0" c_shapetype="line" net="" stroke-linejoin="round"/><circle cx="3724" cy="2738" r="6" stroke-width="1" fill="none" layerid="15" id="gge4149" locked="0"  /><circle cx="3724.5" cy="3259.622" r="6" stroke-width="1" fill="none" layerid="15" id="gge4159" locked="0"  /><circle cx="4279.619" cy="3210.409" r="6" stroke-width="1" fill="none" layerid="15" id="gge4161" locked="0"  /><circle cx="4279.619" cy="2736" r="6" stroke-width="1" fill="none" layerid="15" id="gge4163" locked="0"  /><circle cx="4102" cy="2857" r="10" stroke-width="1" fill="none" layerid="15" id="gge4252" locked="0"  /><circle cx="4127.5" cy="2856.5" r="10" stroke-width="1" fill="none" layerid="15" id="gge4258" locked="0"  /><circle cx="4152.5" cy="2856.5" r="10" stroke-width="1" fill="none" layerid="15" id="gge4264" locked="0"  /><circle cx="3852" cy="2842" r="10" stroke-width="1" fill="none" layerid="15" id="gge4270" locked="0"  /><circle cx="3877.5" cy="2842" r="10" stroke-width="1" fill="none" layerid="15" id="gge4276" locked="0"  /><circle cx="3852" cy="2870" r="10" stroke-width="1" fill="none" layerid="15" id="gge4282" locked="0"  /><circle cx="3877.5" cy="2870" r="10" stroke-width="1" fill="none" layerid="15" id="gge4288" locked="0"  /></svg>` In Inkscape, the result is this (I selected the rectangle I need to delete, showing its properties on the right): ![image.png](//image.easyeda.com/pullimage/BfQxs9mjP1hZdyoIE7wcslCFYSo6u4GDJIcDxTHv.png) As you can see in the EasyEDA screenshot, my Mechanical layer has the "+" signs in the outer corners. But in Inkscape there is a surrounding rectangle.
Reply
UserSupport 2 years ago
hi Yes, the editor will add a extra box to make the image good for view
Reply
Login or Register to add a comment
goToTop
你现在访问的是EasyEDA海外版,建议访问速度更快的国内版 https://lceda.cn(需要重新注册)
如果需要转移工程请在个人中心 - 工程 - 工程高级设置 - 下载工程,下载后在https://lceda.cn/editor 打开保存即可。
有问题联系QQ 3001956291 不再提醒
svg-battery svg-battery-wifi svg-books svg-more svg-paste svg-pencil svg-plant svg-ruler svg-share svg-user svg-logo-cn svg-double-arrow -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus-@1x -mockplus-

Cookie Notice

Our website uses essential cookies to help us ensure that it is working as expected, and uses optional analytics cookies to offer you a better browsing experience. To find out more, read our Cookie Notice