view release on metacpan or search on metacpan
elisp/perl-minlint.el view on Meta::CPAN
(defun perl-minlint-set-mode-line-alert (err)
(cond (err
(setq perl-minlint-saved-color-cookie
(mapc (lambda (f)
(face-remap-add-relative f
':background "orange"))
perl-minlint-alert-face)))
(t
(when perl-minlint-saved-color-cookie
(mapc (lambda (ck)
(face-remap-remove-relative ck))
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Phoebe/Web.pm view on Meta::CPAN
my $stream = shift;
old_serve_css_via_http($stream);
$log->info("Adding more CSS via HTTP (for dark mode)");
$stream->write(<<'EOT');
@media (prefers-color-scheme: dark) {
body { color: #eeeee8; background-color: #333333; }
a:link { color: #1e90ff }
a:hover { color: #63b8ff }
a:visited { color: #7a67ee }
}
EOT
lib/App/Phoebe/Web.pm view on Meta::CPAN
$log->info("Serving CSS via HTTP");
$stream->write("HTTP/1.1 200 OK\r\n");
$stream->write("Content-Type: text/css\r\n");
$stream->write("Cache-Control: public, max-age=86400, immutable\r\n"); # 24h
$stream->write("\r\n");
$stream->write("html { max-width: 70ch; padding: 2ch; margin: auto; color: #111; background: #ffe; }\n");
$stream->write(".del { color: rgb(222,56,43); }\n"); # diff: deleted
$stream->write(".ins { color: rgb(57,181,74); }\n"); # diff: inserted
}
sub serve_index_via_http {
lib/App/Phoebe/Web.pm view on Meta::CPAN
4 => "0,111,184",
5 => "118,38,113",
6 => "44,181,233",
7 => "204,204,204");
$code = join("", map {
"<span style=\"color: rgb($rgb{$_}); background-color: rgb($rgb{$_})\">$_</span>";
} split //, $code);
return $code;
}
sub serve_rss_via_http {
view all matches for this distribution
view release on metacpan or search on metacpan
pod/examples.pod view on Meta::CPAN
I<What color is a mirror? It depends whom you ask. ;-)>
You get numbers to fill into C<"\e[BGm">, C<"\e[FGm"> or C<"\e[BG;FGm"> to get
a color and close it with C<"\e[m">. There are twice twice 8 different colors
for dim & bright and for background & foreground. Hence the multiplication of
escape codes and of values to fill them.
This fills C<@A(RGV)> in B<-A> twice, the 2nd time looping over the 1st list,
as though it had been given on the command line. It maps it to the 16-fold
number format to print the header, swallowing every other number with 0-width.
view all matches for this distribution
view release on metacpan or search on metacpan
pod/examples.pod view on Meta::CPAN
I<What color is a mirror? It depends whom you ask. ;-)>
You get numbers to fill into C<"\e[BGm">, C<"\e[FGm"> or C<"\e[BG;FGm"> to get
a color and close it with C<"\e[m">. There are twice twice 8 different colors
for dim & bright and for background & foreground. Hence the multiplication of
escape codes and of values to fill them.
This fills C<@A(RGV)> in B<-A> twice, the 2nd time looping over the 1st list,
as though it had been given on the command line. It maps it to the 16-fold
number format to print the header, swallowing every other number with 0-width.
view all matches for this distribution
view release on metacpan or search on metacpan
script/proxyforurl view on Meta::CPAN
%= stylesheet begin
body {
margin-top: 5rem;
}
nav {
background: rgba(0, 0, 0, 0.1);
backdrop-filter: saturate(150%) blur(18px);
border-bottom: 1px solid var(--muted-border-color);
position: fixed;
top: 0;
left: 0;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/ptimeout.pm view on Meta::CPAN
my $stderr_buffer = '';
my $held_line;
# Loop while the process we're monitoring does its thang
while(1) {
# The background process is running, and its STDERR is being captured.
# If it's said anything on its STDERR, flush it to the *real* STDERR.
_pump_stderr(
$stderr_reader,
\$stderr_buffer,
\$held_line,
view all matches for this distribution
view release on metacpan or search on metacpan
"--fg COLOR_NAME"
Force chart foreground color.
"--bg COLOR_NAME"
Force chart background color.
"--[no]loadavg"
Use load average <https://en.wikipedia.org/wiki/Load_(computing)>
metric instead of CPU utilization. You might want to set the "--max"
threshold since this is an absolute value and has varying ranges on
"status-right-length" to 48.
Color scheme
If you only see the memory usage bars but no CPU utilization chart,
that's because your terminal's color scheme need an explicit distinction
between foreground and background colors. For instance, "red on red
background" will be displayed as a red block on such terminals. Thus,
you may need the ANSI bright attribute for greater contrast, or maybe
consider switching to the 256-color palette. There are some issues with
that, though:
1. Other color schemes (notably, solarized
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/remarkpl/public/basic.css view on Meta::CPAN
body { font-family: 'Droid Serif'; }
a { color: #222; }
h1, h2, h3 { font-family: 'Yanone Kaffeesatz'; font-weight: normal; }
img { max-width: 100%; }
.remark-container { background: #222; }
.remark-slide-scaler { box-shadow: none; }
.remark-slide-content { background: #f8f8f4; color: #111; }
.remark-code, .remark-inline-code { font-family: 'Ubuntu Mono'; }
.inverse { background: #222; color: #dde; }
.inverse.contrast { background: #000; color: #fff; }
.inverse a { color: #dde; }
.inverse h1, .inverse h2 { color: #f3f3f3; line-height: 0.8em; }
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/revealup.pm view on Meta::CPAN
## This is a third title
---
## This is a forth title
<!-- .slide: data-background="#f70000" data-transition="page" -->
You can add slide attributes like above.
Note:
This is a speaker note. It can be viewed in the speaker mode, just press S during the presentation to view notes and other useful information.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/ruler.pm view on Meta::CPAN
args => {
length => {
schema => ['int*', min=>0],
cmdline_aliases => {l=>{}},
},
background_pattern => {
schema => ['str*', min_len=>1],
default => '-',
cmdline_aliases => {bg=>{}},
},
background_color => {
schema => ['str*'],
},
major_tick_every => {
schema => ['int*', min=>1],
lib/App/ruler.pm view on Meta::CPAN
args => {},
},
{
summary => 'White ruler with red marks and numbers',
args => {
background_color => "black on_white",
minor_tick_character => '',
major_tick_color => "red on_white",
number_color => "bold red on_white",
},
},
lib/App/ruler.pm view on Meta::CPAN
my %args = @_;
my $ruler_len = $args{length} // $term_width;
my $use_color;
# draw background
my $bgpat = $args{background_pattern} // '-';
my $ruler = $bgpat x (int($ruler_len / length($bgpat)) + 1);
if ($args{background_color}) {
$use_color++;
$ruler = _colored($ruler, $args{background_color});
}
# draw minor ticks
my $mintickchar = $args{minor_tick_character} // '.';
if ($args{minor_tick_color} && length($mintickchar)) {
lib/App/ruler.pm view on Meta::CPAN
This document describes version 0.060 of App::ruler (from Perl distribution App-ruler), released on 2019-07-30.
=head1 TIPS
To see background pattern, disable minor ticking by using C<< -m '' >>.
To disable numbering, set number format to an empty string: C<< -f '' >> or C<<
--number-every 0 >>.
=head1 FUNCTIONS
lib/App/ruler.pm view on Meta::CPAN
".........|10.......|20.......|30.......|40.......|50.......|60.......|70.......|80.......|90.......|100......|110......|120......|130......|140......|150......|160......|170......|180......|19"
=item * White ruler with red marks and numbers:
ruler(
background_color => "black on_white",
major_tick_color => "red on_white",
minor_tick_character => "",
number_color => "bold red on_white"
);
lib/App/ruler.pm view on Meta::CPAN
Arguments ('*' denotes required arguments):
=over 4
=item * B<background_color> => I<str>
=item * B<background_pattern> => I<str> (default: "-")
=item * B<length> => I<int>
=item * B<major_tick_character> => I<str> (default: "|")
view all matches for this distribution
view release on metacpan or search on metacpan
# Sources stored from previous downloads have already been md5 checked
sbozyp_print_stderr("$pkg->{PKGNAME}: using previously downloaded src: $src_filename\n");
sbozyp_copy("$CONFIG{SRCDIR}/$src_filename", "$staging_dir/$src_filename");
} else {
my $md5 = $url_md5{$url};
sbozyp_system('wget', '-e', 'background=off', '-O', "$staging_dir/$src_filename", $url);
unless ($skip_md5) {
my $got_md5 = do {
my $fh = sbozyp_open('<', "$staging_dir/$src_filename");
binmode($fh);
Digest::MD5->new->addfile($fh)->hexdigest;
view all matches for this distribution
view release on metacpan or search on metacpan
script/screenorama view on Meta::CPAN
<!DOCTYPE html>
<html>
<head>
<title>screenorama - <%= app->config->{program} %> <%= join ' ', @{app->config->{program_args}} %></title>
%= stylesheet begin
body { background: #111; padding: 8px; }
body, .shell { font-size: 13px; font-family: monospace; color: #eee; margin: 0; padding: 0; }
pre { margin: 0; padding: 0; }
.status { border-top: 1px solid #333; margin-top: 20px; }
input { position: absolute; left: -600px; }
% end
script/screenorama view on Meta::CPAN
screenorama.replaceColors.span = false;
if (!a && typeof b == 'undefined') { return closing; } // regular
if (termColors[b]) style.push('color: ' + termColors[b]);
else if (termColors[a]) style.push('background-color: ' + termColors[a]);
if (a == 1) { style.push('font-weight: bold'); }
else if (a == 4) { style.push('text-decoration: underline'); }
screenorama.replaceColors.span = true;
view all matches for this distribution
view release on metacpan or search on metacpan
script/cdif view on Meta::CPAN
option --dark --dark-cmy
Automatic setting is done by L<Getopt::EX::termcolor> module and it
works with macOS Terminal.app and iTerm.app, and other XTerm
compatible terminals. This module accepts environment variable
L<TERM_BGCOLOR> as a terminal background color. For example, use
C<000> or C<#000000> for black and C<555> or C<#FFFFFF> for white.
Option B<--autocolor> is set by default, so override it to do nothing
to disable.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/sdview/Output/Formatted.pm view on Meta::CPAN
$_nextblank = !!$typestyle{blank_after};
my @lines = $text->split( qr/\n/ );
@lines or @lines = ( String::Tagged->new ) if defined $leader;
# If there's a background set, then space-pad every line to the same width
# so it looks neater on the terminal
# https://rt.cpan.org/Ticket/Display.html?id=140536
if( defined $typestyle{bg} ) {
my $width = max map { length $_ } @lines;
$_ .= " " x ( $width - length $_ ) for @lines;
view all matches for this distribution