improve further
This commit is contained in:
parent
f2252f2d46
commit
f346e51d87
21
LS47.scad
21
LS47.scad
|
@ -2,12 +2,9 @@
|
||||||
// No license, but send me a hello if you use this for some good purpose.
|
// No license, but send me a hello if you use this for some good purpose.
|
||||||
// -- Mirek Kratochvil <exa.exa@gmail.com>
|
// -- Mirek Kratochvil <exa.exa@gmail.com>
|
||||||
|
|
||||||
//TODO: round corners?
|
font = "FiraMono";
|
||||||
|
|
||||||
font = "Consolas"; //URW Bookman L looks nicely here as well
|
alphabet = "ru";
|
||||||
font2 = "Droid Sans Mono";
|
|
||||||
|
|
||||||
alphabet = "en";
|
|
||||||
|
|
||||||
//inch-sized tiles look imperial.
|
//inch-sized tiles look imperial.
|
||||||
tilesize=25.4;
|
tilesize=25.4;
|
||||||
|
@ -22,11 +19,13 @@ corner=tileheight*2;
|
||||||
|
|
||||||
//accomodate for Ё
|
//accomodate for Ё
|
||||||
if (alphabet=="ru") {
|
if (alphabet=="ru") {
|
||||||
fontheight=fontheight*0.9;
|
fontheight=fontheight*0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
module arrow(n) {
|
module arrow(n) {
|
||||||
if (n>=1) for(i=[0:n-1]) translate([i-(n-1)/2,0,0]) polygon([[0.45,0],[0,0.7],[-0.45,0]]);
|
if (n>=1)
|
||||||
|
for(i=[0:n-1]) translate([i-(n-1)/2,0,0])
|
||||||
|
polygon([[0.45,0],[0,0.7],[-0.45,0]]);
|
||||||
}
|
}
|
||||||
|
|
||||||
//this produces one tile
|
//this produces one tile
|
||||||
|
@ -49,7 +48,7 @@ module tilec(letter, x, y, c) {
|
||||||
color("white") {
|
color("white") {
|
||||||
translate([tilesize*(0.5-dx*0.13),tilesize*(0.275-dy*0.13),tileheight*.51])
|
translate([tilesize*(0.5-dx*0.13),tilesize*(0.275-dy*0.13),tileheight*.51])
|
||||||
linear_extrude (height=tileheight/2)
|
linear_extrude (height=tileheight/2)
|
||||||
text(letter, font=font, size=tilesize*.45,
|
text(letter, font=font, size=tilesize*.48,
|
||||||
halign="center", valign="baseline");
|
halign="center", valign="baseline");
|
||||||
}
|
}
|
||||||
color("white")
|
color("white")
|
||||||
|
@ -81,13 +80,13 @@ module tiles(letters) {
|
||||||
if (alphabet=="en") {
|
if (alphabet=="en") {
|
||||||
// latin variant of tiles
|
// latin variant of tiles
|
||||||
tiles(
|
tiles(
|
||||||
["□", "A", "B", "C", "D", "E", "F",
|
["□", "A", "B", "C", "D", "E", "F",
|
||||||
"G", "H", "I", "J", "K", "L", "M",
|
"G", "H", "I", "J", "K", "L", "M",
|
||||||
"N", "O", "P", "Q", "R", "S", "T",
|
"N", "O", "P", "Q", "R", "S", "T",
|
||||||
"U", "V", "W", "X", "Y", "Z", ".",
|
"U", "V", "W", "X", "Y", "Z", ".",
|
||||||
"/", ":", "?", "!", "'", "(", ")",
|
",", ":", "?", "!", "'", "(", ")",
|
||||||
"0", "1", "2", "3", "4", "5", "6",
|
"0", "1", "2", "3", "4", "5", "6",
|
||||||
"7", "8", "9", ",", "-", "+", "*"]
|
"7", "8", "9", "+", "-", "*", "/"]
|
||||||
);
|
);
|
||||||
} else if (alphabet=="ru") {
|
} else if (alphabet=="ru") {
|
||||||
// variant of tiles thanks to Stas Bushuev
|
// variant of tiles thanks to Stas Bushuev
|
||||||
|
|
Loading…
Reference in a new issue