
답변1
부인 성명:이것은 TikZ 답변이 아니지만 어쨌든 ...
취득텍스트 개요에 관한 이 질문에 대한 Thruston의 답변참고로 변형된 H 문자를 얻으려면 다음을 수행할 수 있습니다. 이는 개념 증명이므로 개별 문자에만 작동하지만 추가 조정을 통해 전체 단어에 적용하는 것이 가능합니다.
\documentclass{standalone}
\usepackage[latex,shellescape]{gmp}
\begin{document}
\begin{mpost}[name=H]
picture nice;
path P, PP;
nice := image(draw thelabel(\btex H etex,origin));
%Transformation
vardef T(expr p) =
save x, y;
x := xpart p; y := ypart p;
%0.01 by guessing. Play with other values
(x,0.01x*y)
enddef;
%Assumes a cyclic path
%It can be done better
vardef TT(expr P) =
T(point 0 of P)
.. controls
T(postcontrol 0 of P) and T(precontrol 1 of P)
for j = 1 upto (length P - 1):
.. T(point j of P)
.. controls T(postcontrol j of P)
and T(precontrol (j+1) of P)
endfor
.. cycle
enddef;
for i within nice:
if textual i:
for j = 1 upto length textpart i:
string s; s := substring(j-1,j) of textpart i;
picture g; g := glyph ASCII s of fontpart i scaled 1/10;
picture r; r := image(
for x within g:
picture xx; xx := image(draw g);
%75 is also guessing. Try other values
%Bad filling. It works for the letter H, tho.
fill TT(pathpart x shifted (llcorner xx - ulcorner xx + 75right)) withcolor
if greypart x = 1:
1
else:
(1,0.843,0)
fi;
endfor
);
draw r;
endfor
fi
endfor
\end{mpost}\usempost{H}%
\end{document}
비교를 위해 다음은 문자 Q에 대한 결과입니다(가짜 채우기 적용).