--- trunk/lib/Frey/Introspect.pm 2008/11/16 16:36:53 358 +++ trunk/lib/Frey/Introspect.pm 2008/11/17 18:42:51 380 @@ -8,6 +8,9 @@ use File::Slurp; use List::Util; +use PPI; +use PPI::HTML; + use lib 'lib'; extends 'Frey::ClassLoader'; @@ -228,18 +231,40 @@ $table .= qq||; my $pod = Frey::Pod->new( class => $class )->markup; + $pod = $pod->{body} if ref($pod); + + my $Document = PPI::Document->new( $self->class_path( $class ) ); + + # Create a reusable syntax highlighter + my $Highlight = PPI::HTML->new( +# line_numbers => 1, +# page => 1, +# colors => { +# line_number => '#CCCCCC', +# number => '#990000', +# }, + ); + + # Spit out the HTML + my $source = $Highlight->html( $Document ); + +# $source =~ s{^.*
]+>}{}s; +# $source =~ s{$_| } grep { $class->can($_) } Frey::Run->runnable ); $runnable = " runnable: $runnable" if $runnable; my $html = { - title => "Introspect $class", - body => qq|