Locale:...aketext(3)

πŸ“¦
version 1.036 Β· 2 versions
, in fedora 43

🌸 Locale::TextDomain::OO::Plugin::Expand::Maketext 🌸

okay bestie, welcome to the Locale:...aketext(3) manual page, aka the little plugin that hands you extra maketext methods πŸ’– we're doing Perl, we're doing i18n, and honestly? it's giving iconic.

$Id: Maketext.pm 651 2017-05-31 18:10:43Z steffenw $

$HeadURL: svn+ssh://steffenw@svn.code.sf.net/p/perl-gettext-oo/code/module/trunk/lib/Locale/TextDomain/OO/Plugin/Expand/Maketext.pm $


✨ VERSION ✨

1.027 β€” that's the one, no cap πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

So this module gives you additional maketext methods, kinda like what Locale::Maketext::Simple does β€” the whole point is you can run that vibe on projects that are already using Locale::Maketext at the moment. no need to yeet your existing setup, we're just adding sparkle ✨

And listen: if you wanna run maketext with a different context (msgctxt), you run the method maketext_p. that's the whole thing, that's the assignment πŸ’…


🌈 SYNOPSIS 🌈

    my $loc = Locale::Text::TextDomain::OO->new(
        plugins => [ qw (
            Expand::Maketext
            ...
        )],
        ...
    );

Optional type formatting β€” go peek at Locale::Utils::PlaceholderMaketext for the possible methods bestie πŸ‘€

    $loc->expand_maketext->formatter_code($code_ref);

πŸ’– SUBROUTINES/METHODS πŸ’–

🌸 method expand_maketext

It hands you back the Locale::Utils::PlaceholderMaketext object so you can set some options on it. that's it, that's the method 🫢

    my $expander_object = $self->expand_maketext;

⭐ translation methods

πŸŽ€ method maketext

This method includes the expansion as 'quant' or '*'. so slay.

    print $loc->maketext(
        'Hello World!',
    );

    print $loc->maketext(
        'Hello [_1]!',
        'Steffen',
    );

    print $loc->maketext(
        '[quant,_1,file read,files read]',
        $num_files,
    );

πŸ’œ method maketext_p (allows the context)

yes bestie, the _p means it takes a context. watch:

    print $loc->maketext_p (
        'time',
        'to',
    );

    print $loc->maketext_p (
        'destination',
        'to',
    );

    print $loc->maketext_p (
        'destination',
        'from [_1] to [_2]',
        'Chemnitz',
        'Erlangen',
    );

    print $loc->maketext_p(
        'maskulin',
        'Mr. [_1] has [*,_2,book,books].',
        $name,
        $books,
    );

🧚 methods Nmaketext, Nmaketext_p

Okay so here's the tea β˜• the extractor looks for "maketext('..." and it has no problem with "<$loc-"Nmaketext('...>>.

That's literally the whole idea of the N-Methods. big brain energy fr fr.

    $loc->Nmaketext('...');
    $loc->Nmaketext_p('...', '...');

πŸ”₯ EXAMPLE πŸ”₯

Inside of this distribution is a directory named example. Run this *.pl files. go on, run 'em, live a little πŸ’…


πŸ’€ DIAGNOSTICS πŸ’€

confess


πŸ“ CONFIGURATION AND ENVIRONMENT πŸ“

none


🌟 DEPENDENCIES 🌟

  • Locale::Utils::PlaceholderMaketext
  • Moo::Role

πŸ™ˆ INCOMPATIBILITIES πŸ™ˆ

not known β€” we love a drama-free module


😭 BUGS AND LIMITATIONS 😭

none


πŸ‘‘ SEE ALSO πŸ‘‘

  • Locale::TextDoamin::OO
(yes, that spelling is exactly what the page says β€” copying it character for character, not my business to fix πŸ’–)

✨ AUTHOR ✨

Steffen Winkler


Copyright (c) 2009 - 2017, Steffen Winkler "<steffenw at cpan.org>". All rights reserved.

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


and that's the whole page, bestie β€” you ate that 🫢✨

this masterpiece was brought to you by perl v5.42.0, dated 2025-07-25, and generated from the Locale:...aketext(3) page in User Contributed Perl Documentation. mwah πŸ’‹

πŸ“¦ where this page comes from