App-financeta

 view release on metacpan or  search on metacpan

lib/App/financeta/gui/editor.pm  view on Meta::CPAN

        } else {
            push @arr, $regexes->{$k};
        }
        push @arr, $color_scheme{$k} // $color_scheme{plain},
    }
    my $hlres = $ed->hiliteREs;
    $ed->hiliteREs([@arr, @$hlres]);
    return $mw;
}

sub update_editor {
    my ($self, $rules, $tabname, $vars, $hidden) = @_;
    $self->tab_name($tabname) if defined $tabname;
    $self->compiler->preset_vars($vars) if defined $vars;
    $self->main->editor_edit->text($rules);
    unless ($hidden) {
        $self->main->show;
        $self->main->bring_to_front;
    }
    1;
}

lib/App/financeta/gui/progress_bar.pm  view on Meta::CPAN

    );
    $bar->{-progress} = 0;
    $bar->repaint;
    if (defined $bar->owner) {
        $bar->owner->pointerType(cr::Wait);
        $bar->owner->repaint;
    }
    return $bar;
}

sub update {
    my ($self, $val) = @_;
    ## is percentage
    if (defined $val and ($val > 0 and $val < 1)) {
        $self->bar->{-progress} = ($val * $self->bar_width);
    } elsif (defined $val) {#is absolute
        $self->bar->{-progress} = $val;
    } else {
        $self->bar->{-progress} += 5;
    }
    $self->bar->repaint;

lib/App/financeta/gui/tradereport.pm  view on Meta::CPAN

                $p->{items} = [
                    sort {$$b[$col] <=> $$a[$col]}
                    @{$self->{items}}
                ];
            }
            $p->clear_event;
        },
    );
}

sub update {
    my ($self, $tabname, $buysells) = @_;
    $self->tab_name($tabname) if defined $tabname;
    return unless defined $buysells;
    my $longs = $buysells->{longs};
    my $shorts = $buysells->{shorts};
    my $qty = $buysells->{quantity};
    my @items = ();
    my $tz = $self->parent->timezone;
    my $grosspnl = $buysells->{longs_pnl} + $buysells->{shorts_pnl};
    if (defined $longs and not $longs->isnull and not $longs->isempty) {

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 0.475 second using v1.00-cache-2.02-grep-82fe00e-cpan-4673cadbf75 )