This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 206035 - Incorrect background property value validation/completion
Summary: Incorrect background property value validation/completion
Status: VERIFIED FIXED
Alias: None
Product: web
Classification: Unclassified
Component: CSS Visual Tools (show other bugs)
Version: 7.2
Hardware: PC Mac OS X
: P3 normal with 1 vote (vote)
Assignee: Marek Fukala
URL:
Keywords:
: 206110 206837 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-12-06 21:29 UTC by Marek Fukala
Modified: 2012-10-10 07:48 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marek Fukala 2011-12-06 21:29:06 UTC
When adding generated unit tests for parsing css rules I found two following problems:

div {
    background:#fff url(../images/google) no-repeat center left;
}

1)
====
reports "left" as unexpected token although the notation is correct.

Caused by a bug in the GrammarResolver not being able to properly resolve grammar like:

"[ center | a ] && [ center | b ]" and input "center a"

the same happens also for the LIST (||) group type:

"[ center | a ] || [ center | b ]" and input "center a"

2)
====
url(../images/google)") is not properly resolved as uri due to the unquoted non-literal characters. (bug in the uri grammar)

added unit tests for both problems:

GrammarResolverTest.testBackground2
GrammarResolverTest.testBgPosition
GrammarResolverTest.testBgPositionDetail

GrammarResolverTest.testURI
Comment 1 Marek Fukala 2011-12-08 09:48:20 UTC
*** Bug 206110 has been marked as a duplicate of this bug. ***
Comment 2 Marek Fukala 2012-04-27 09:32:10 UTC
*** Bug 206837 has been marked as a duplicate of this bug. ***
Comment 3 Marek Fukala 2012-04-27 09:34:05 UTC
More samples from the issue 206837:

div{
background-position: center center, 20% 80%, top left, bottom right;
}

div{
border-image: url(../img/examp/li/borderimage1.png) 9 round;
}
Comment 4 Marek Fukala 2012-05-17 10:31:46 UTC
>url(../images/google)") is not properly resolved as uri due to the unquoted
>non-literal characters. (bug in the uri grammar)

This has already been fixed in the **** branch. But not easily transplantable (depends on complicated changes).
Comment 5 Marek Fukala 2012-05-17 12:01:36 UTC
problem #1 fixed in web-main#c0e731b4b6d0
Comment 6 Quality Engineering 2012-05-18 09:52:17 UTC
Integrated into 'main-golden', will be available in build *201205180400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/c0e731b4b6d0
User: Marek Fukala <mfukala@netbeans.org>
Log: #206035 - Incorrect background property value validation/completion
Comment 7 Vladimir Riha 2012-06-04 07:07:10 UTC
Sorry, I'm afraid I have to reopen it. The problem #1 is really fixed but not the examples from issue #206837

div{
background-position: center center, 20% 80%, top left, bottom right;
}

div{
border-image: url(img/examp/li/borderimage1.png) 9 round;
}


It still shows errors:
- "Unexpected value token ,"
- "Unexpected value token round"
Comment 8 Vladimir Riha 2012-06-04 07:07:38 UTC
(In reply to comment #7)
> Sorry, I'm afraid I have to reopen it. The problem #1 is really fixed but not

Product Version: NetBeans IDE Dev (Build 201206040001)
Java: 1.7.0_04; Java HotSpot(TM) Client VM 23.0-b21
System: Windows 7 version 6.1 running on x86; cp1250; en_US (nb)
Comment 9 Marek Fukala 2012-10-09 13:13:01 UTC
background-position: center center, 20% 80%, top left, bottom right 

works fine in latest dev build, 

border-image: url(img/examp/li/borderimage1.png) 9 round

fixed in web-main#6101184864c4
Comment 10 Quality Engineering 2012-10-10 03:05:00 UTC
Integrated into 'main-golden', will be available in build *201210100002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/6101184864c4
User: Marek Fukala <mfukala@netbeans.org>
Log: #206035 - fixing border-image grammar
Comment 11 Vladimir Riha 2012-10-10 07:48:41 UTC
thanks, all samples work fine

Product Version: NetBeans IDE Dev (Build 201210100002)
Java: 1.7.0_10-ea; Java HotSpot(TM) Client VM 23.6-b03
System: Linux version 3.2.0-31-generic-pae running on i386; UTF-8; en_US (nb)