Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 352262

Summary: Link to Name Style preference page from Generate Getters and Setters page
Product: [Tools] CDT Reporter: Marc-André Laperle <malaperle>
Component: cdt-refactoringAssignee: Marc-André Laperle <malaperle>
Status: RESOLVED FIXED QA Contact: Emanuel Graf <emanuel>
Severity: enhancement    
Priority: P3 CC: cdtdoug, eclipse.sprigogin
Version: 8.0Flags: eclipse.sprigogin: review+
Target Milestone: 8.0.1   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
Link to Name Style preference page patch
malaperle: iplog-
Link to Name Style preference page patch, revised
malaperle: iplog-
Link to Name Style preference page patch, revised malaperle: iplog-

Description Marc-André Laperle CLA 2011-07-16 01:25:45 EDT
It is not obvious that the code generated by Generate Getters ans Setters can be customized by the new Name Style preference page. I suggest adding an hyperlink to the preference page, similar to how JDT's Generate Getters ans Setters links to Code Templates.
Comment 1 Marc-André Laperle CLA 2011-07-17 01:04:58 EDT
Created attachment 199789 [details]
Link to Name Style preference page patch
Comment 2 Marc-André Laperle CLA 2011-07-17 01:07:20 EDT
The patch adds a link to Name Style and refreshes the function declarations when preferences change.
Comment 3 Sergey Prigogin CLA 2011-07-17 22:32:40 EDT
(In reply to comment #2)

The patch looks good except for a minor wording issue. The message "The generated code of the getters/setters may be configured on the Name Style preference page." is somewhat misleading since the generated code may depend on other preferences too. It would be more accurate to say: "The names of getters and setters may be configured on the Name Style preference page."

I would also put a spacer above the message to separate it visually from the "Place implementation in header file" check box.
Comment 4 Marc-André Laperle CLA 2011-07-18 02:16:20 EDT
(In reply to comment #3)
> (In reply to comment #2)
> I would also put a spacer above the message to separate it visually from the
> "Place implementation in header file" check box.

A spacer? An horizontal separator or just some empty space?
Comment 5 Sergey Prigogin CLA 2011-07-18 02:19:27 EDT
(In reply to comment #4)
> A spacer? An horizontal separator or just some empty space?

Just some empty space.
Comment 6 Marc-André Laperle CLA 2011-07-18 02:34:55 EDT
Created attachment 199805 [details]
Link to Name Style preference page patch, revised

(In reply to comment #3)
> (In reply to comment #2)
> 
> The patch looks good except for a minor wording issue. The message "The
> generated code of the getters/setters may be configured on the Name Style
> preference page." is somewhat misleading since the generated code may depend on
> other preferences too. It would be more accurate to say: "The names of getters
> and setters may be configured on the Name Style preference page."

You're right, that's better.

> I would also put a spacer above the message to separate it visually from the
> "Place implementation in header file" check box.

Space added.
Comment 7 Marc-André Laperle CLA 2011-07-18 02:35:30 EDT
Comment on attachment 199805 [details]
Link to Name Style preference page patch, revised

Woops, patch includes other changes.
Comment 8 Marc-André Laperle CLA 2011-07-18 02:53:13 EDT
Created attachment 199806 [details]
Link to Name Style preference page patch, revised
Comment 9 Marc-André Laperle CLA 2011-07-18 03:04:15 EDT
Fixed in 8.0 and master.
Comment 10 CDT Genie CLA 2011-07-18 03:19:55 EDT
*** cdt git genie on behalf of 352262 ***

    Bug 352262 - Link to Name Style preference page from Generate Getters
    and Setters page

[*] http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=11963d3ec565744758c2fa4ac4b8e947ee71733d
Comment 11 CDT Genie CLA 2011-07-18 03:19:56 EDT
*** cdt git genie on behalf of 352262 ***

    Bug 352262 - Link to Name Style preference page from Generate Getters
    and Setters page

[*] http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=7184f89ff4591bc3da4dd80f34c2be83bc556aea