How to 'difference' one vector from another? - inkscape

I'm trying to create a mute music button:
And I'm doing it by drawing 2 vector lines over a music note vector. I've tried selecting them every which way but whenever I try to take the path → difference nothing happens. Ideally I'd like to subtract the big like (white in the above image) and add the small line.
How would I do this?

Got it. You have to be in the edit paths mode:
You may also need to convert the object into a path. Path → Object to Path

Related

Kate Text Editor regexp for CNC code alteration on PC

When using some CAM software, the CNC code is usually generated properly with spaces.
But for example when moved to "Citizen Cincom L20" machine via USB or network and edited there it lose spaces and also lose semicolons while preserving new lines which does work as semicolons anyway.
But since editing of CNC program happens in 3 places: CAM Software(ESPRIT in this case), CNC machine controller and also via text editor on the computer as postprocessor in ESPRIT is garbage.I've come up with this regex
([0-9]{1,2})([A-Z])
\1 \2
so
G1G99X5.4Z-.5F.12
Becomes
G1 G99 X5.4 Z-.5 F.12
that works in Kate to space everything back again for clearer reviwing of code. The only issue about it is that I need to do that manually for every file and I would like to automate it, preferably via Kate, so it would happen upon opening any ????.PRG plain text files.
But I do not exactly know how such happening should be called is it like macro or what ?
I'm looking for some suggestions to accomplish this. Or maybe some alternative solutions
First, go to View -> Tool Views -> Show Search and Replace. You will see
Make sure you:
Enable {} regex option on the right as you are using a regex
Enable "AB" option on the right that enables case sensitive matching
Select In Folder value from the dropdown on the right
Fill out the regex, replacement, Folder and the Filter fields with the appropriate values
Click Search button.
You will see the results in a separate pane and Replace / Replace Checked buttons will become enabled.
Review the replacements and click Replace Checked:
Then you may check the updated file contents, and if you are satisifed with the results, use Save All, also by pressing CTRL+L.

Clear font.ttf from unused glyphs

For example I want to use this .ttf font file:
https://www.onlinewebfonts.com/download/3b2646a48566403a55f62ceddbecbe18
It contains 29,064 glyphs.
I want to leave in it only the letters I use.
A short example: どこでもタップしてプレイ
So, from 29,064 it will be only 12 characters left. In my actual situation if will be around 300 glyphs.
Basically, I want to dramatically decrease it's file-size by removing unused glyphs
Is there a way to implement this by some script? I'm on macOS.
Or some app can do this and how exactly? Is there a real life example?
upd: answer from this question not working, throwing errors:
./subset.pl --chars="どこでもタップしてプレイ" /Users/User/Desktop/1.ttf /Users/User/Desktop/2.ttf
Wide character in subroutine entry at Font/Subsetter.pm line 1496.
In that question there are recommendation of use fixed this bug repo: https://github.com/fnp/librarian/blob/master/librarian/font-optimizer/subset.pl
And with it executing same command gives another errors:
Uses unhandled table 'BASE'
Uses forbidden table 'CFF '
As font file I used that from first link, just renamed it to 1.ttf

SVG Font Inkscape two not connected path as one glyph

Can anyone tell me, why I can't use not connected paths as one glyph? e.g. I selected 2 stars and wanted to make them as one glyphe, but Inkscape just use the first selected one.
Maybe you are looking for the combine operation (CTRL-K) which will make a single path out of two. Should do what you expect if they are not overlapping, else try the path union (CTRL-+)

Can't get the same CRS for different layers in QGIS

I have just begun to fiddle around with QGIS. Now, I have a .shp file containing a map of Sweden. I want to add a vector point to that map by adding a new point layer through the Delimited Text File plugin. The CSV file that I'm importing contains the following data:
id,lat,long
1,62.30000,14.10000
The dot appears on the screen but very far away from the country map. I assumed that was because the layers were set to different CRS, but after right-clicking each layer and changing the CRS to WGS 84, nothing changes. What am I doing wrong here?
EDIT: Just go it to work by deleting the point layer, changing the coordinates in the CSV file to SWEREF99 TM, and importing the layer anew with the same plugin. But I'm still wondering if it's not possible to change the CRS after importing?
You can always change a layer's CRS by overriding the setting in layer properties - General tab. Note that the features are not reprojected when you change this setting. You are just telling QGIS to interpret the coordinates differently.

How to get paper.print() to work?

I have been trying to get the following Raphael code to just write something on the screen with no luck!
paper.print(30, 15, "TEXT", paper.getFont("Arial"), 20).attr({fill: "black"});
Is there anything else you need to do to get the text in the paper?!?!!?
You need to cufonize a font, being sure to indicate that the cufonized font should register itself with Raphael, and include the resulting .js file before you can use getFont to retrieve it (there are no fonts available by default). If you check, I'm reasonably sure you'll find that paper.getFont("Arial") is returning undefined.
Cufon essentially converts every glyph in a provided font into its vector equivalent -- Raphael simply transforms and sequences those paths to produce output.