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 216372

Summary: Uses Preview in the Options doesn't work at all
Product: php Reporter: Martin Fousek <marfous>
Component: EditorAssignee: Tomas Mysik <tmysik>
Status: NEW ---    
Severity: normal    
Priority: P3    
Version: 7.2   
Hardware: All   
OS: All   
See Also: https://netbeans.org/bugzilla/show_bug.cgi?id=255833
https://netbeans.org/bugzilla/show_bug.cgi?id=255832
Issue Type: ENHANCEMENT Exception Reporter:

Description Martin Fousek 2012-08-03 14:44:24 UTC
Product Version: NetBeans IDE 7.2 (Build 201207171143)
Java: 1.6.0_29; Java HotSpot(TM) 64-Bit Server VM 20.4-b02
System: Linux version 3.2.0-27-generic running on amd64; UTF-8; en_US (nb)

Not sure if this issue PHP issue or Options issue, feel free to reassign. Anyway if you are trying options in Options->Editor->Formating->PHP->Uses and checking/unchecking the checkboxes, nothing happens in the right area of the window - in the preview.
Comment 1 Ondrej Brejla 2012-08-07 07:40:18 UTC
"Uses preview" is just a static PHP code. That "Fix Uses" formatting is not handled by PHP formatter. It's there just as an example (I think that all possible options are described there?). It's handled by Fix Uses action which is not triggered by changing Uses options. Not sure if I can put it into motion somehow :/
Comment 2 SebastianZ 2015-10-09 11:02:34 UTC
(In reply to Ondrej Brejla from comment #1)
> "Uses preview" is just a static PHP code. That "Fix Uses" formatting is not
> handled by PHP formatter.

That is not obvious at all, because all other options there refer to the code formatter available through Source > Format.

Therefore I see two solutions:
1. Add a comment to the preview code clarifying that the code shown there is static code and that the options belong to the 'Fix Uses' feature.
2. Move the options to the 'Fix Uses' dialog opening when calling Source > Fix Uses... and always show that dialog

I prefer the second solution, because it avoids mixing options for different features into the same UI, it makes it absolutely clear where those options belong to and it allows the user to see and adjust what actions will be performed by 'Fix Uses' before they are applied.

Sebastian
Comment 3 SebastianZ 2015-10-09 11:48:16 UTC
I've now split the second solution into its own issues (bug 255833 and bug 255832). So this issue can be resolved using the first solution.

Sebastian
Comment 4 Tomas Mysik 2016-06-03 07:01:26 UTC
Taking over.