You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(24) |
Sep
|
Oct
(7) |
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(4) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(5) |
Oct
|
Nov
|
Dec
|
2005 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2008 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Björn Höh. <hoe...@us...> - 2008-07-05 19:45:22
|
Update of /cvsroot/perl-css/CSS-SAC In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7222 Modified Files: Changes MANIFEST Makefile.PL README SAC.pm Added Files: LICENSE Log Message: some kwalitee fixes --- NEW FILE: LICENSE --- See SAC.pm. Index: Changes =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/Changes,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- Changes 19 Sep 2004 19:58:07 -0000 1.7 +++ Changes 5 Jul 2008 19:45:27 -0000 1.8 @@ -1,7 +1,7 @@ Revision history for Perl extension CSS::SAC. -0.07 ... - - ... +0.08 Sun Jul 5 21:47 2008 + - Some kwalitee fixes 0.06 Sun Oct 19 21:47 2004 - Module now maintained by Bjoern Hoehrmann Index: MANIFEST =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/MANIFEST,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- MANIFEST 17 Aug 2001 18:14:22 -0000 1.2 +++ MANIFEST 5 Jul 2008 19:45:27 -0000 1.3 @@ -1,4 +1,5 @@ Changes +LICENSE MANIFEST Makefile.PL README @@ -27,3 +28,4 @@ lib/CSS/SAC/Writer.pm t/00base.t t/05selector.t +t/98podsyn.t Index: Makefile.PL =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/Makefile.PL,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Makefile.PL 17 Aug 2001 17:50:15 -0000 1.2 +++ Makefile.PL 5 Jul 2008 19:45:27 -0000 1.3 @@ -8,4 +8,15 @@ Text::Balanced => '1.84', Class::ArrayObjects => '0.04', }, + + ($] >= 5.005 ? ## Add these new keywords supported since 5.005 + (ABSTRACT_FROM => 'SAC.pm', # retrieve abstract from module + AUTHOR => 'Robin Berjon') : ()), + + LICENSE => 'perl', + 'dist' => { + PREOP => 'chmod 600 Makefile.PL', + TARFLAGS => '--group=cpan --owner=bjoern -cvf', + }, + ); Index: README =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/README,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- README 17 Aug 2001 17:50:15 -0000 1.2 +++ README 5 Jul 2008 19:45:27 -0000 1.3 @@ -1,5 +1,5 @@ -### CSS::SAC 0.04 - a SAC parser for Perl +### CSS::SAC 0.08 - a SAC parser for Perl This module implements a SAC interface for Perl. It has a good deal Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- SAC.pm 19 Sep 2004 19:58:07 -0000 1.13 +++ SAC.pm 5 Jul 2008 19:45:27 -0000 1.14 @@ -20,7 +20,7 @@ %DIM_MAP %FUNC_MAP ); -$VERSION = '0.06_1'; +$VERSION = '0.08'; use CSS::SAC::ConditionFactory qw(); use CSS::SAC::SelectorFactory qw(); |
From: Björn Höh. <hoe...@us...> - 2008-07-05 19:45:20
|
Update of /cvsroot/perl-css/CSS-SAC/t In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7222/t Added Files: 98podsyn.t Log Message: some kwalitee fixes --- NEW FILE: 98podsyn.t --- # 99pod.t -- Minimally check POD for problems. # # $Id: 98podsyn.t,v 1.1 2008/07/05 19:45:27 hoehrmann Exp $ use strict; use warnings; use Test::More; eval "use Test::Pod 1.00"; plan skip_all => "Test::Pod 1.00 required for testing POD" if $@; all_pod_files_ok(); |
From: <hoe...@us...> - 2005-01-22 18:56:18
|
Update of /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC/Selector In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8875 Modified Files: ToXPath.pm Log Message: Added todo for quote marks inside contains expressions Index: ToXPath.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC/Selector/ToXPath.pm,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ToXPath.pm 19 Sep 2004 21:02:11 -0000 1.1 +++ ToXPath.pm 22 Jan 2005 18:56:06 -0000 1.2 @@ -5,6 +5,27 @@ # todo: haven't looked at the code for years, # probably needs some work... +# @@ +# +# All occurences of contains(...) need some re-work to deal with +# selectors that involve quote marks, the outer marks should be +# choosen based on the inner marks and if the string contains +# both types of quote marks, the string needs to be split up and +# use concat(...) to put them together again. For example +# +# :contains(\"\'\"\') +# +# should become +# +# ... contains(..., concat('"', "'", '"', "'")) ... +# +# This can be done by e.g. the following code +# +# my $result = join ", ", map { /'/ ? qq("$_") : qq('$_') } +# grep length, +# split(/(['"])/, $string); +# + sub CSS::SAC::Selector::Sibling::_GetElement { shift->SiblingSelector->_GetElement } sub CSS::SAC::Selector::Descendant::_GetElement |
From: <hoe...@us...> - 2004-09-19 21:02:19
|
Update of /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC/Selector In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4647 Added Files: ToXPath.pm Log Message: Experimental Selector 2 XPath converter --- NEW FILE: ToXPath.pm --- # ToXPath.pm -- Convert CSS Selectors to XPath # # $Id: ToXPath.pm,v 1.1 2004/09/19 21:02:11 hoehrmann Exp $ # todo: haven't looked at the code for years, # probably needs some work... sub CSS::SAC::Selector::Sibling::_GetElement { shift->SiblingSelector->_GetElement } sub CSS::SAC::Selector::Descendant::_GetElement { shift->SimpleSelector->_GetElement } sub CSS::SAC::Selector::Conditional::_GetElement { shift->SimpleSelector->_GetElement } sub CSS::SAC::Selector::Element::_GetElement { shift } sub CSS::SAC::Condition::Content::ToXPath { sprintf "contains(., '%s')", shift->Data } sub CSS::SAC::Condition::Lang::ToXPath { sprintf "lang('%s')", shift->Lang } sub CSS::SAC::Condition::Attribute::ToXPath { my $cond = shift; my $name = $cond->LocalName; my $nsur = $cond->NamespaceURI; my $valu = $cond->Value; my $apfx = ""; $apfx .= "local-name() = '$name'" if defined $name; $apfx .= " and " if defined $nsur and length $apfx; $apfx .= "namespace-uri() = '$nsur'" if defined $nsur; $apfx = "[$apfx]" if length $apfx; if ($cond->is_type(ID_CONDITION)) { sprintf "id('%s') and count(id('%s')/preceding::* | ". "id('%s')/ancestor::*) = count(preceding::* | ancestor::*)", $valu, $valu, $valu } elsif ($cond->is_type(ATTRIBUTE_CONDITION) && $cond->Specified) { sprintf "\@*%s[. = '%s']", $apfx, $valu } elsif ($cond->is_type(ATTRIBUTE_CONDITION)) { sprintf "\@*%s", $apfx } elsif ($cond->is_type(STARTS_WITH_ATTRIBUTE_CONDITION)) { sprintf "\@*%s[starts-with(., '%s')]", $apfx, $valu } elsif ($cond->is_type(CONTAINS_ATTRIBUTE_CONDITION)) { sprintf "\@*%s[contains(., '%s')]", $apfx, $valu } elsif ($cond->is_type(BEGIN_HYPHEN_ATTRIBUTE_CONDITION)) { sprintf "\@*%s[. = '%s' or starts-with(., '%s-')]", $apfx, $valu, $valu } elsif ($cond->is_type(ENDS_WITH_ATTRIBUTE_CONDITION)) { sprintf "\@*%s[substring(., string-length(.) - ". "string-length('%s') + 1) = '%s']", $apfx } elsif ($cond->is_type(ONE_OF_ATTRIBUTE_CONDITION)) { sprintf "\@*%s[. = '%s' or starts-with(., '%s') or contains(.,' %s ') ". "or substring(., string-length(.) - string-length('%s'))= ' %s']", $apfx, $valu, $valu, $valu, $valu } elsif ($cond->is_type(CLASS_CONDITION)) { # We assume all class='...' attributes are class # attributes and classes are separated by spaces sprintf "\@*[local-name() = 'class' and namespace-uri() = '']". "[. = '%s' or starts-with(., '%s ') or contains(., ' %s ') or ". "substring(., string-length(.) - string-length('%s')) = ' %s']", $valu, $valu, $valu, $valu } else { return } } sub CSS::SAC::Condition::Negative::ToXPath { my $cond = shift; my $args = shift || {}; # workaround for a CSS::SAC bug, it considers # :not(:foo) equivalent to :not(*:foo) @@@ my $not = $cond->Condition->isa('CSS::SAC::Selector::Conditional') ? $cond->Condition->Condition->ToXPath($args) : $cond->Condition->ToXPath($args); return unless defined $not; $not = "*" unless length $not; return "not(" . $not . ")"; } sub CSS::SAC::Condition::Positional::ToXPath { my $cond = shift; my $args = shift || {}; my $result = ""; my $epfx = $args->{parent}->_GetElement->ToXPath($args); $epfx = "[$epfx]" if length $epfx; # *|*:only-of-type cannot be expressed using XPath return if (not(length $epfx) or $epfx eq "[self::*]") and $cond->Type; $result .= "parent::* and " unless $cond->Type; my $p = $cond->Position; if ($p eq "1") { $result .= "not(preceding-sibling::*" . ($cond->Type ? "$epfx" : "") . ")" } elsif ($p eq "-1") { $result .= "not(following-sibling::*" . ($cond->Type ? "$epfx" : "") . ")" } elsif ($p =~ /^(?:-?(\d+)?n(?:\+(\d+))?)|odd|even|\d+$/x) { my ($x, $y, $n) = ($1, $2, undef); $n = $p =~ /^-/ ? '<' : '>'; ($x, $y) = (2, 0) if $p eq "even"; ($x, $y) = (2, 1) if $p eq "odd"; ($x, $y, $n) = ($p, $p, '<') if $p =~ /^\d+$/; $x = 1 unless defined $x; $y = 0 unless defined $y; my $test = "preceding-sibling::*"; $test .= "$epfx" if $cond->Type; $result .= "count($test) + 1 $n= $y and ((count($test) - $y + 1) mod $x) = 0"; } else { return } } sub CSS::SAC::Condition::Combinator::ToXPath { my $cond = shift; my $args = shift || {}; return unless $cond->is_type(AND_CONDITION); my $first = $cond->FirstCondition->ToXPath($args); my $second = $cond->SecondCondition->ToXPath($args); return unless defined $first and defined $second; return "$first and $second"; } sub CSS::SAC::Condition::ToXPath { my $cond = shift; my $args = shift || {}; if ($cond->is_type(IS_EMPTY_CONDITION)) { return "not(* or text())" } elsif ($cond->is_type(IS_ROOT_CONDITION)) { return "not(ancestor::*)" } elsif ($cond->is_type(ONLY_CHILD_CONDITION)) { return "not(preceding-sibling::*) and not(following-sibling::*)" } my $epfx = $args->{parent}->_GetElement->ToXPath($args); $epfx = "[$epfx]" if length $epfx; if ($cond->is_type(ONLY_TYPE_CONDITION)) { return "not(preceding-sibling::*$epfx or following-sibling::*$epfx)" } else { return } } sub CSS::SAC::Selector::Conditional::ToXPath { my $self = shift; my $args = shift || {}; my $result = ""; my $x = $self->SimpleSelector->ToXPath({ %$args, parent => $self }); my $y = $self->Condition->ToXPath({ %$args, parent => $self->SimpleSelector }); return unless defined $x and defined $y; $result .= $x; $result .= " and " if length $result; $result .= $y; return $result; } sub CSS::SAC::Selector::Descendant::ToXPath { my $self = shift; my $args = shift || {}; my $result = ""; my $x = $self->AncestorSelector->ToXPath({ %$args, parent => $self }); my $y = $self->SimpleSelector->ToXPath({ %$args, parent => $self }); return unless defined $x and defined $y; $result .= $self->is_type(CHILD_SELECTOR) ? "parent::*" : "ancestor::*"; $result .= "[$x]" if length $x; $result .= " and $y" if length $y; return $result; } sub CSS::SAC::Selector::Element::ToXPath { my $self = shift; my $result = ""; my $local = $self->LocalName; my $ns = $self->NamespaceURI; if (defined $local) { $result .= "local-name() = '$local'" } if (defined $local && defined $ns) { $result .= " and " } if (defined $ns) { $result .= "namespace-uri() = '$ns'" } $result = "self::*" unless length $result; return $result; } sub CSS::SAC::Selector::Sibling::ToXPath { my $self = shift; my $args = shift || {}; my $result = ""; my $x = $self->Selector->ToXPath({ %$args, parent => $self }); my $y = $self->SiblingSelector->ToXPath({ %$args, parent => $self }); return unless defined $x and defined $y; $result .= $self->is_type(DIRECT_ADJACENT_SELECTOR) ? "preceding-sibling::*[1]" : "preceding-sibling::*"; $result .= "[$x]" if length $x; $result .= " and $y" if length $y; return $result; } |
From: <hoe...@us...> - 2004-09-19 19:58:17
|
Update of /cvsroot/perl-css/CSS-SAC In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22748 Modified Files: Changes SAC.pm Log Message: shift version number for post-0.06 work Index: Changes =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/Changes,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- Changes 19 Sep 2004 19:50:36 -0000 1.6 +++ Changes 19 Sep 2004 19:58:07 -0000 1.7 @@ -1,5 +1,8 @@ Revision history for Perl extension CSS::SAC. +0.07 ... + - ... + 0.06 Sun Oct 19 21:47 2004 - Module now maintained by Bjoern Hoehrmann - More accurate behavior wrt to namespace declarations Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- SAC.pm 19 Sep 2004 19:13:20 -0000 1.12 +++ SAC.pm 19 Sep 2004 19:58:07 -0000 1.13 @@ -20,7 +20,7 @@ %DIM_MAP %FUNC_MAP ); -$VERSION = '0.06'; +$VERSION = '0.06_1'; use CSS::SAC::ConditionFactory qw(); use CSS::SAC::SelectorFactory qw(); |
From: <hoe...@us...> - 2004-09-19 19:50:45
|
Update of /cvsroot/perl-css/CSS-SAC In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21265 Modified Files: Changes Log Message: prepare for 0.06 Index: Changes =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/Changes,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- Changes 19 Sep 2004 19:13:20 -0000 1.5 +++ Changes 19 Sep 2004 19:50:36 -0000 1.6 @@ -1,7 +1,8 @@ Revision history for Perl extension CSS::SAC. -0.06 ... - - ... +0.06 Sun Oct 19 21:47 2004 + - Module now maintained by Bjoern Hoehrmann + - More accurate behavior wrt to namespace declarations 0.05 2003-07-07 19:56 - changed some code (it's not really a bugfix, it changes from a |
From: <hoe...@us...> - 2004-09-19 19:37:57
|
Update of /cvsroot/perl-css/CSS-SAC/t In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18393 Modified Files: 05selector.t Log Message: avoid warnings... Index: 05selector.t =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/t/05selector.t,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- 05selector.t 21 Oct 2001 18:56:05 -0000 1.2 +++ 05selector.t 19 Sep 2004 19:37:38 -0000 1.3 @@ -8,6 +8,9 @@ use strict; +# todo: avoid length on undef below +no warnings; + #- test parsing and selector handling ------------------------------# my $tst_result = ''; |
From: <hoe...@us...> - 2004-09-19 19:13:29
|
Update of /cvsroot/perl-css/CSS-SAC In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12696 Modified Files: Changes SAC.pm Log Message: merge with CPAN 0.05 Index: Changes =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/Changes,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- Changes 17 Aug 2001 19:55:25 -0000 1.4 +++ Changes 19 Sep 2004 19:13:20 -0000 1.5 @@ -1,6 +1,16 @@ Revision history for Perl extension CSS::SAC. -0.04 Ddd Mmm dd hh:mm:ss yyyy (in progress) +0.06 ... + - ... + +0.05 2003-07-07 19:56 + - changed some code (it's not really a bugfix, it changes from a + bug to a less likely one -- a real fix will come later) thanks + to a report and patch from Briac Pilpré. + - fixed a bug to parse attr(color, color) correctly, thanks to + Bjoern Hoehrmann. + +0.04 Sat Jul 06 16:13 2001 - fixed a bug in Text::Balanced that caused blocks to be incorrectly extracted when they contained backslashed followed by a newline. As a result Text::Balanced 1.84 is now required. @@ -16,7 +26,6 @@ - added _ to the IDENT characters (it's in CSS2 Errata) - fixed @page parsing (patch by SG) - 0.03 Mon Apr 23 16:44:16 2001 - switched all to Class::ArrayObjects (which used to be CSS::SAC::Helpers::ArrayObjects) - provide both standard and perlified names for methods Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- SAC.pm 11 Aug 2003 02:55:43 -0000 1.11 +++ SAC.pm 19 Sep 2004 19:13:20 -0000 1.12 @@ -20,7 +20,7 @@ %DIM_MAP %FUNC_MAP ); -$VERSION = '0.03_90'; +$VERSION = '0.06'; use CSS::SAC::ConditionFactory qw(); use CSS::SAC::SelectorFactory qw(); @@ -438,7 +438,18 @@ # parse the rule my $rule; warn "[SAC] parsing rule\n" if DEBUG; - ($rule,$css,undef) = Text::Balanced::extract_bracketed($css,q/{}'"/,qr/\s*/); #" + + ### BUG + # The Text::Balanced extractions below are not correct since they don't take + # comments into account. With the first one, it'll fail on apostrophes in + # comments, with the latter, on unbalanced apos and } in comments and + # apos-strings. The latter is used currently because it is less likely to fail, + # but what is needed is a real parser that steps inside the black parsing out + # comments and property values. The good news is that we have most of the bits + # to do that right already. + + #($rule,$css,undef) = Text::Balanced::extract_bracketed($css,q/{}'"/,qr/\s*/); #" + ($rule,$css,undef) = Text::Balanced::extract_bracketed($css,q/{}"/,qr/\s*/); #" $sac->parse_rule(\$rule); # end of the rule @@ -1192,6 +1203,7 @@ sub parse_property_value { my $sac = shift; my $css = shift; + my $att = shift || 0; $$css =~ s/^\s*//; @@ -1203,7 +1215,7 @@ $sac->parse_comments($css); # exit conditions - if (! length($$css) or $$css =~ m/^\s*(?:;|!)/) { + if (! length($$css) or $$css =~ m/^\s*(?:;|!)/ or ($att and $$css =~ s/^\s*(?:\))//)) { last; } @@ -1275,18 +1287,21 @@ } # functions - elsif ( - ($value,$$css,$text) = Text::Balanced::extract_bracketed($$css,q/()'"/,qr/$RE_IDENT/) - and - length $text - ) { +# elsif ( +# ($value,$$css,$text) = Text::Balanced::extract_bracketed($$css,q/()'"/,qr/$RE_IDENT/) +# and +# length $text +# ) { + elsif ($$css =~ s/^($RE_IDENT)\(//) { # cleanup the func and args - $text = lc $text; - $value =~ s/^\(\s*//; - $value =~ s/\s*\)$//; - $value =~ s/^(?:"|')//; #" - $value =~ s/(?:"|')$//; #" +# $text = lc $text; +# $value =~ s/^\(\s*//; +# $value =~ s/\s*\)$//; +# $value =~ s/^(?:"|')//; #" +# $value =~ s/(?:"|')$//; #" + $text = lc $1; + $value = $sac->parse_property_value($css, 1); # get the appropriate type if ($FUNC_MAP{$text}) { |
From: Bj?rn H?h. <hoe...@us...> - 2003-08-11 02:55:46
|
Update of /cvsroot/perl-css/CSS-SAC In directory sc8-pr-cvs1:/tmp/cvs-serv30494 Modified Files: SAC.pm Log Message: fix for various namespace related bugs Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- SAC.pm 24 Oct 2001 10:54:50 -0000 1.10 +++ SAC.pm 11 Aug 2003 02:55:43 -0000 1.11 @@ -744,7 +744,7 @@ $lname = ($3 eq '*')?undef:$3; if (defined $2 and $2 eq '|') { if (!$1) { - $ns = $sac->[_ns_map_]->{'#default'} || ''; + $ns = ''; # |E matches elements in no namespace } elsif ($1 eq '*') { $ns = undef; # undef means all, '' means default @@ -754,7 +754,9 @@ } } else { - $ns = $sac->[_ns_map_]->{'#default'} || ''; + # E matches elements in the default namespace or + # any namespace if no default namespace is declared + $ns = $sac->[_ns_map_]->{'#default'} || undef; } # push it @@ -791,7 +793,7 @@ $lname = ($3 eq '*')?undef:$3; if (defined $2 and $2 eq '|') { if (!$1) { - $ns = $sac->[_ns_map_]->{'#default'} || ''; + $ns = '' # [|a] matches attributes in no namespace; } elsif ($1 eq '*') { $ns = undef; # undef means all, '' means default @@ -801,7 +803,7 @@ } } else { - $ns = $sac->[_ns_map_]->{'#default'} || ''; + $ns = ''; # [a] is equivalent to [|a] } # if there's more, parse on |
From: Allen D. <all...@us...> - 2002-01-18 04:30:18
|
Update of /cvsroot/perl-css/Parse/t In directory usw-pr-cvs1:/tmp/cvs-serv29461/t Removed Files: t Log Message: re-releasing this package. sorry i was _such_ an amateur before. not that i'm pro now... anyway, enjoy. --- t DELETED --- |
From: Allen D. <all...@us...> - 2002-01-18 04:30:18
|
Update of /cvsroot/perl-css/Parse/CSS/Adaptor In directory usw-pr-cvs1:/tmp/cvs-serv29461/CSS/Adaptor Modified Files: Default.pm Test.pm Log Message: re-releasing this package. sorry i was _such_ an amateur before. not that i'm pro now... anyway, enjoy. Index: Default.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS/Adaptor/Default.pm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Default.pm 2001/08/27 16:18:47 1.1.1.1 +++ Default.pm 2002/01/18 04:30:14 1.2 @@ -1,9 +1,9 @@ -package Parse::CSS::Adaptor::Default; +package CSS::Adaptor::Default; use strict; use vars qw($VERSION @ISA); -our $VERSION = '0.01'; -@ISA = 'Parse::CSS::Adaptor'; +$VERSION = '0.05'; +@ISA = 'CSS::Adaptor'; sub name { return "Default" } Index: Test.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS/Adaptor/Test.pm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Test.pm 2001/08/27 16:18:47 1.1.1.1 +++ Test.pm 2002/01/18 04:30:14 1.2 @@ -1,9 +1,9 @@ -package Parse::CSS::Adaptor::Test; +package CSS::Adaptor::Test; use strict; use vars qw($VERSION @ISA); -our $VERSION = '0.01'; -@ISA = 'Parse::CSS::Adaptor'; +$VERSION = '0.05'; +@ISA = 'CSS::Adaptor'; sub name { return "Test" } |
From: Allen D. <all...@us...> - 2002-01-18 04:30:18
|
Update of /cvsroot/perl-css/Parse/CSS In directory usw-pr-cvs1:/tmp/cvs-serv29461/CSS Modified Files: Adaptor.pm Style.pm Removed Files: CSS.xs Log Message: re-releasing this package. sorry i was _such_ an amateur before. not that i'm pro now... anyway, enjoy. Index: Adaptor.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS/Adaptor.pm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Adaptor.pm 2001/08/27 16:18:47 1.1.1.1 +++ Adaptor.pm 2002/01/18 04:30:14 1.2 @@ -1,14 +1,14 @@ -package Parse::CSS::Adaptor; +package CSS::Adaptor; use strict; use warnings; use vars qw($VERSION); -our $VERSION = 0.1; +$VERSION = 0.05; use lib '../../'; use Carp qw(croak confess); use overload '""' => 'toString'; -use Parse::CSS::Adaptor; +use CSS::Adaptor; sub new { my $class = shift; Index: Style.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS/Style.pm,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Style.pm 2001/08/27 16:40:39 1.2 +++ Style.pm 2002/01/18 04:30:14 1.3 @@ -1,14 +1,14 @@ -package Parse::CSS::Style; +package CSS::Style; use strict; use warnings; use vars qw($VERSION); -my $VERSION = 0.1; +$VERSION = 0.05; use lib '../../'; use Carp qw(croak confess); use overload '""' => 'toString'; -use Parse::CSS::Adaptor; +use CSS::Adaptor; sub new { my $class = shift; @@ -26,9 +26,9 @@ return $self->{adaptor} unless $option; $self->{adaptor} = $option and return 1 - if (ref($option) =~ /Parse::CSS::Adaptor/); + if (ref($option) =~ /CSS::Adaptor/); - my $adaptorclass = "Parse::CSS::Adaptor::$option"; + my $adaptorclass = "CSS::Adaptor::$option"; croak "Can't find adaptor $adaptorclass: $!" unless (eval "require $adaptorclass"); --- CSS.xs DELETED --- |
From: Allen D. <all...@us...> - 2002-01-18 04:30:18
|
Update of /cvsroot/perl-css/Parse In directory usw-pr-cvs1:/tmp/cvs-serv29461 Modified Files: CSS.pm Makefile.PL Log Message: re-releasing this package. sorry i was _such_ an amateur before. not that i'm pro now... anyway, enjoy. Index: CSS.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS.pm,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- CSS.pm 2001/08/27 16:31:59 1.2 +++ CSS.pm 2002/01/18 04:30:14 1.3 @@ -1,17 +1,17 @@ -package Parse::CSS; +package CSS; -require 5.005_62; use strict; use warnings; use vars qw($VERSION); -our $VERSION = 0.1; +use vars qw($VERSION); +$VERSION = 0.06; use lib '..'; use Carp qw(croak confess); use Parse::RecDescent; $Parse::RecDescent::skip = '[ \t\n]*'; -use Parse::CSS::Style; -use Parse::CSS::Adaptor; +use CSS::Style; +use CSS::Adaptor; sub new { my $class = shift; @@ -77,7 +77,7 @@ my @return; my @option = ref $option eq 'ARRAY' ? @$option : $option; foreach my $o (@option){ - if(ref $o eq 'Parse::CSS::Style'){ + if(ref $o eq 'CSS::Style'){ $self->{style}->{$o} = $o; } else { push @return, $self->{style}->{$o}; @@ -102,7 +102,7 @@ my $parser = new Parse::RecDescent <<'EOPARSER'; sheet: statement(s) statement: selector '{' declaration(s?) '}' {push @$return, $style} - statement: <rulevar: local $style = new Parse::CSS::Style> + statement: <rulevar: local $style = new CSS::Style> declaration: property ':' value ';' declaration: <rulevar: local $property> selector: /\S+/ {$style->selector($item{__PATTERN1__})} @@ -127,16 +127,16 @@ =head1 NAME -Parse::CSS - Perl extension for blah blah blah +CSS - Perl Object oriented access to Cascading Style Sheets (CSS) =head1 SYNOPSIS - use Parse::CSS; - blah blah blah + use CSS; + ... =head1 DESCRIPTION -Stub documentation for Parse::CSS, created by h2xs. It looks like the +Stub documentation for CSS, created by h2xs. It looks like the author of the extension was negligent enough to leave the stub unedited. @@ -146,26 +146,10 @@ None by default. - -=head1 HISTORY - -=over 8 - -=item 0.01 - -Original version; created by h2xs 1.20 with options - - -p - Parse - -CAf - Parse::CSS - -=back - - =head1 AUTHOR -A. U. Thor, a.u.thor@a.galaxy.far.far.away +Allen Day <all...@uc...> +Copyright (c) 2001-2002 =head1 SEE ALSO Index: Makefile.PL =================================================================== RCS file: /cvsroot/perl-css/Parse/Makefile.PL,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Makefile.PL 2001/08/27 16:18:46 1.1.1.1 +++ Makefile.PL 2002/01/18 04:30:14 1.2 @@ -2,9 +2,9 @@ # See lib/ExtUtils/MakeMaker.pm for details of how to influence # the contents of the Makefile that is written. WriteMakefile( - 'NAME' => 'Parse::CSS', + 'NAME' => 'CSS', 'VERSION_FROM' => 'CSS.pm', # finds $VERSION - 'PREREQ_PM' => {}, # e.g., Module::Name => 1.1 + 'PREREQ_PM' => {Parse::RecDescent => 1.0}, # e.g., Module::Name => 1.1 'LIBS' => [''], # e.g., '-lm' 'DEFINE' => '', # e.g., '-DHAVE_SOMETHING' 'INC' => '', # e.g., '-I/usr/include/other' |
From: Robin B. <da...@us...> - 2001-10-24 10:54:53
|
Update of /cvsroot/perl-css/CSS-SAC In directory usw-pr-cvs1:/tmp/cvs-serv2375 Modified Files: SAC.pm Log Message: updated TODO Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- SAC.pm 2001/10/21 18:56:05 1.9 +++ SAC.pm 2001/10/24 10:54:50 1.10 @@ -1725,7 +1725,13 @@ - find a way to make the '-' prefix to properties optional - - switch to spec names (?) + - add a filter that switches events to spec names, and that can be used + directly through an option + + - add DOM-like hasFeature support (in view of SAC 3) + + - prefix all constants with SAC_. Keep the old ones around for a few + versions, importable with :old-constants. - update docs |
From: Bj?rn H?h. <hoe...@us...> - 2001-10-21 18:56:09
|
Update of /cvsroot/perl-css/CSS-SAC In directory usw-pr-cvs1:/tmp/cvs-serv8745 Modified Files: SAC.pm Log Message: finishing uri() to url() patches I've missed... Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- SAC.pm 2001/10/21 18:35:31 1.8 +++ SAC.pm 2001/10/21 18:56:05 1.9 @@ -100,7 +100,7 @@ counter => COUNTER_FUNCTION, counters => COUNTERS_FUNCTION, rect => RECT_FUNCTION, - uri => URI, + url => URI, rgb => RGBCOLOR, ); |
From: Bj?rn H?h. <hoe...@us...> - 2001-10-21 18:56:09
|
Update of /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC In directory usw-pr-cvs1:/tmp/cvs-serv8745/lib/CSS/SAC Modified Files: TestWriter.pm Writer.pm Log Message: finishing uri() to url() patches I've missed... Index: TestWriter.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC/TestWriter.pm,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- TestWriter.pm 2001/08/17 18:00:01 1.3 +++ TestWriter.pm 2001/10/21 18:56:05 1.4 @@ -172,7 +172,7 @@ my $uri = shift; my $media = shift; - $dh->[_out_]->($dh, "\n\@import uri($uri) " . join(', ', @$media) . ";\n"); + $dh->[_out_]->($dh, "\n\@import url($uri) " . join(', ', @$media) . ";\n"); } #---------------------------------------------------------------------# @@ -190,7 +190,7 @@ $dh->[_nsmap_]->{$uri} = $prefix; } - $dh->[_out_]->($dh, "\n\@namespace" . ((defined $prefix)?" $prefix ":' ') . "uri($uri);\n"); + $dh->[_out_]->($dh, "\n\@namespace" . ((defined $prefix)?" $prefix ":' ') . "url($uri);\n"); } #---------------------------------------------------------------------# Index: Writer.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/lib/CSS/SAC/Writer.pm,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- Writer.pm 2001/08/17 19:56:03 1.4 +++ Writer.pm 2001/10/21 18:56:05 1.5 @@ -212,7 +212,7 @@ my $uri = shift; my $media = shift; - $dh->[_out_]->($dh, "\n\@import uri($uri) " . join(', ', @$media) . ";\n"); + $dh->[_out_]->($dh, "\n\@import url($uri) " . join(', ', @$media) . ";\n"); } #---------------------------------------------------------------------# @@ -230,7 +230,7 @@ $dh->[_nsmap_]->{$uri} = $prefix; } - $dh->[_out_]->($dh, "\n\@namespace" . ((defined $prefix)?" $prefix ":' ') . "uri($uri);\n"); + $dh->[_out_]->($dh, "\n\@namespace" . ((defined $prefix)?" $prefix ":' ') . "url($uri);\n"); } #---------------------------------------------------------------------# |
From: Bj?rn H?h. <hoe...@us...> - 2001-10-21 18:56:09
|
Update of /cvsroot/perl-css/CSS-SAC/t In directory usw-pr-cvs1:/tmp/cvs-serv8745/t Modified Files: 05selector.t Log Message: finishing uri() to url() patches I've missed... Index: 05selector.t =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/t/05selector.t,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- 05selector.t 2001/08/17 13:32:15 1.1.1.1 +++ 05selector.t 2001/10/21 18:56:05 1.2 @@ -18,7 +18,7 @@ my $sac = CSS::SAC->new({ DocumentHandler => $tsth }); my $css1 = <<'EOCSS'; -@namespace foo uri('http://www.foo.com/'); +@namespace foo url('http://www.foo.com/'); * {} E {} foo|* {} foo|E {} [bar] {} [foo|bar] {} E[bar] {} [bar='baz'] {} |
From: Robin B. <ro...@kn...> - 2001-10-21 18:49:27
|
On Sunday 21 October 2001 20:35, Bj?rn H?hrmann wrote: > Log Message: > fixes local scope for RE_IDENT and uri() to url() Thanks ! -- _______________________________________________________________________ Robin Berjon <ro...@kn...> -- CTO k n o w s c a p e : // venture knowledge agency www.knowscape.com ----------------------------------------------------------------------- Critic, n.: A person who boasts himself hard to please because nobody tries to please him. |
From: Bj?rn H?h. <hoe...@us...> - 2001-10-21 18:35:34
|
Update of /cvsroot/perl-css/CSS-SAC In directory usw-pr-cvs1:/tmp/cvs-serv4754 Modified Files: SAC.pm Log Message: fixes local scope for RE_IDENT and uri() to url() Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- SAC.pm 2001/10/21 17:19:37 1.7 +++ SAC.pm 2001/10/21 18:35:31 1.8 @@ -46,7 +46,7 @@ /xs; # matches a valid CSS ident (this may be wrong, needs testing) -my $RE_IDENT = qr/ +$RE_IDENT = qr/ (?:(?:\\(?:(?:[a-fA-F0-9]{1,6}[\t\x20])|[ \x32-\xff]))|[a-zA-Z\x80-\xff]) (?:(?:\\(?:(?:[a-fA-F0-9]{1,6}[\t\x20])|[ \x32-\xff]))|[a-zA-Z\x80-\xff0-9_-])* /xs; @@ -563,12 +563,12 @@ while ($$css =~ s/^\s*\@namespace\s+//i) { my ($prefix,$uri); # first get the prefix - if ($$css !~ /^uri\(/ and $$css =~ s/^($RE_IDENT)\s+//) { + if ($$css !~ /^url\(/ and $$css =~ s/^($RE_IDENT)\s+//) { $prefix = $1; } # then get the uri - if ($$css =~ s/^uri\(//) { + if ($$css =~ s/^url\(//) { $$css =~ s/^((?:$RE_STRING)|([^\)]*))\s*//; $uri = $1; $uri =~ s/^(?:'|")//; # " |
From: Robin B. <da...@us...> - 2001-10-21 17:19:40
|
Update of /cvsroot/perl-css/CSS-SAC In directory usw-pr-cvs1:/tmp/cvs-serv21980/CSS-SAC Modified Files: SAC.pm Log Message: fix bug that didn't provide entire ignorable_at_rule information Index: SAC.pm =================================================================== RCS file: /cvsroot/perl-css/CSS-SAC/SAC.pm,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- SAC.pm 2001/08/17 19:55:25 1.6 +++ SAC.pm 2001/10/21 17:19:37 1.7 @@ -20,7 +20,7 @@ %DIM_MAP %FUNC_MAP ); -$VERSION = '0.04'; +$VERSION = '0.03_90'; use CSS::SAC::ConditionFactory qw(); use CSS::SAC::SelectorFactory qw(); @@ -413,8 +413,9 @@ $at_rule .= ';'; } else { - (undef,$css,undef) = Text::Balanced::extract_bracketed($css,q/{}'"/,qr/\s*/); #" - $at_rule .= $1; + my $block; + ($block,$css,undef) = Text::Balanced::extract_bracketed($css,q/{}'"/,qr/\s*/); #" + $at_rule .= $block; } $sac->[_dh_]->ignorable_at_rule($at_rule) if $sac->[_dh_can_]->{ignorable_at_rule}; |
From: Allen D. <all...@us...> - 2001-08-27 16:40:42
|
Update of /cvsroot/perl-css/Parse/t In directory usw-pr-cvs1:/tmp/cvs-serv7567/t Modified Files: test1.pl Log Message: Style properties now returns hash instead of hashref Index: test1.pl =================================================================== RCS file: /cvsroot/perl-css/Parse/t/test1.pl,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- test1.pl 2001/08/27 16:32:00 1.2 +++ test1.pl 2001/08/27 16:40:39 1.3 @@ -13,4 +13,10 @@ foreach my $style ($css->styles){ print "$style\n"; + + my %properties = $style->properties; + + foreach my $prop (keys %properties){ + print "\t$prop\t".$properties{$prop}."\n"; + } } |
From: Allen D. <all...@us...> - 2001-08-27 16:40:42
|
Update of /cvsroot/perl-css/Parse/CSS In directory usw-pr-cvs1:/tmp/cvs-serv7567/CSS Modified Files: Style.pm Log Message: Style properties now returns hash instead of hashref Index: Style.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS/Style.pm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Style.pm 2001/08/27 16:18:47 1.1.1.1 +++ Style.pm 2001/08/27 16:40:39 1.2 @@ -69,7 +69,7 @@ } else { %return = %h; } - return \%return; + return %return; } #now set the properties |
From: Allen D. <all...@us...> - 2001-08-27 16:32:03
|
Update of /cvsroot/perl-css/Parse/t In directory usw-pr-cvs1:/tmp/cvs-serv4647/t Modified Files: test1.pl Log Message: CSS->styles() passes an array ref now. Index: test1.pl =================================================================== RCS file: /cvsroot/perl-css/Parse/t/test1.pl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- test1.pl 2001/08/27 16:18:47 1.1.1.1 +++ test1.pl 2001/08/27 16:32:00 1.2 @@ -7,4 +7,10 @@ my $css = Parse::CSS->new( -source => './wormbase.css', -debug => 1, - ) + ); + +#my @styles = $css->styles; + +foreach my $style ($css->styles){ + print "$style\n"; +} |
From: Allen D. <all...@us...> - 2001-08-27 16:32:03
|
Update of /cvsroot/perl-css/Parse In directory usw-pr-cvs1:/tmp/cvs-serv4647 Modified Files: CSS.pm Log Message: CSS->styles() passes an array ref now. Index: CSS.pm =================================================================== RCS file: /cvsroot/perl-css/Parse/CSS.pm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- CSS.pm 2001/08/27 16:18:46 1.1.1.1 +++ CSS.pm 2001/08/27 16:31:59 1.2 @@ -72,7 +72,7 @@ sub style { my $self = shift; my $option = shift; - return values %{$self->{style}} unless $option; + return (values %{$self->{style}}) unless $option; my @return; my @option = ref $option eq 'ARRAY' ? @$option : $option; @@ -114,19 +114,9 @@ foreach my $b (@$a){ foreach my $s (@$b){ - $s->adaptor($self->adaptor('Test')); + $s->adaptor($self->adaptor); $s->debug($self->debug); $self->style($s); - } - } - - foreach my $s ($self->styles){ - print $s->adaptor,"\n"; - print $s, "\n"; -# my %p = %{$s->properties}; - my %p = %{$s->converts}; - foreach my $p (keys %p){ - print "\t$p\t=>\t$p{$p}\n"; } } } |
From: Allen D. <all...@us...> - 2001-08-27 16:23:18
|
Update of /cvsroot/perl-css/Parse/blib/lib/Parse/CSS In directory usw-pr-cvs1:/tmp/cvs-serv1029/blib/lib/Parse/CSS Removed Files: Adaptor.pm CSS.xs MANIFEST Style.pm test.pl Log Message: don't really want blib in cvs, now do we? --- Adaptor.pm DELETED --- --- CSS.xs DELETED --- --- MANIFEST DELETED --- --- Style.pm DELETED --- --- test.pl DELETED --- |