X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=lib%2FLaTeX%2FTikZ%2FInterface.pm;h=ef78fa8b1644abb7765861bb95699028f21d0a05;hb=e6c6fbca8df4f8df7bbce2eb98dd260ed51d9141;hp=fa5da48c0bd7b3e825fdcb5dfcdc6d6989789149;hpb=92147217516a40b35ca00c8e08939e8aa5478426;p=perl%2Fmodules%2FLaTeX-TikZ.git diff --git a/lib/LaTeX/TikZ/Interface.pm b/lib/LaTeX/TikZ/Interface.pm index fa5da48..ef78fa8 100644 --- a/lib/LaTeX/TikZ/Interface.pm +++ b/lib/LaTeX/TikZ/Interface.pm @@ -17,13 +17,17 @@ our $VERSION = '0.01'; use Sub::Name (); -sub import { - shift; +=head1 METHODS - register(@_); -} +=head2 C<< register $keyword => $code >> + +Registers C<$code> to be available with C<< Tikz->$keyword >>. + +=cut sub register { + shift; + while (@_ >= 2) { my ($name, $code) = splice @_, 0, 2; @@ -53,6 +57,12 @@ sub register { return; } +=head2 C + +Load all the modules of the L official suite that register a keyword in the interface. + +=cut + sub load { require LaTeX::TikZ::Formatter; # formatter require LaTeX::TikZ::Functor; # functor