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 16310 - abbreviations should be disabled in comments.
Summary: abbreviations should be disabled in comments.
Status: VERIFIED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: Macros (show other bugs)
Version: 3.x
Hardware: PC All
: P2 blocker with 1 vote (vote)
Assignee: Miloslav Metelka
URL:
Keywords: REGRESSION, USABILITY
: 18265 36514 53775 (view as bug list)
Depends on:
Blocks:
 
Reported: 2001-10-05 20:04 UTC by Mathieu Carpentier
Modified: 2007-11-05 13:40 UTC (History)
2 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 Mathieu Carpentier 2001-10-05 20:04:28 UTC
Sometimes I write my comments in french and the word 'le' (means "the" or 
somethin') is often used. Whenever I type 'le' and press SPACE, it's 
automatically completed for 'length'. 

It's not a big problem, just a bit anoying.
Comment 1 Martin Roskanin 2001-10-08 08:53:01 UTC
You have the possibility to remove 'le' abbreviation from editor settings.
Please see Editor Settings - Abbreviations in Global options.
But from UI point of view, perhaps it is better to omit abbreviations feature in 
comment block.
Comment 2 Martin Roskanin 2001-10-11 15:01:09 UTC
Changing to enhancement.
- perhaps it is better to omit abbreviations feature in comment block.
Comment 3 Mathieu Carpentier 2001-10-11 15:18:35 UTC
I just receive message : "Changing to enhancement.
- perhaps it is better to omit abbreviations feature in comment 
block."

This could be a good thing.
Comment 4 Jan Chalupa 2001-11-27 12:26:39 UTC
Target milestone -> 3.3.1.
Comment 5 Martin Roskanin 2001-12-03 09:29:54 UTC
*** Issue 18265 has been marked as a duplicate of this issue. ***
Comment 6 Jan Lahoda 2002-05-06 11:47:37 UTC
A new bug 23138 was created for not-unrolling abbrevs inside the
string literal.
I have a comment to both these:
It is possible that someone will create an abbreviation for phrase
"for future use" and he/she will WANT to unroll it in comments
(similar case can be found for strings). Therefore I do not agree that
disabling  abbreviations in comments (strings) is a good idea. The
only reliable possibility in scope of current editor I see is to mark
each abbreviation (&macro?) with a flag(s) that will say where this
abbreviation should be unrolled.
Comment 7 Marek Grummich 2002-07-22 09:54:34 UTC
Set target milestone to TBD
Comment 8 Marek Grummich 2002-07-22 09:57:59 UTC
Set target milestone to TBD
Comment 9 aaime 2002-11-09 17:43:39 UTC
Another option to abbreviation marking is to 
have a keyboard shortcut that forces the 
abbreviation expansion and an option to avoid 
automatic expansion, just as in code completion (automatic 
or CTRL-SPACE). This is also covered in issue 23571 
Comment 10 Patrick Keegan 2004-04-20 21:51:52 UTC
this has been brought up on nbusers a few times, so I'm raising the
priority and switching to DEFECT since expansion of abbreviations in a
comment is *undesired*.
Comment 11 Patrick Keegan 2004-04-20 21:52:55 UTC
*** Issue 36514 has been marked as a duplicate of this issue. ***
Comment 12 klosels 2004-04-22 21:33:49 UTC
Another suggestion: it would be useful to have some kind of localized
'profiles' for abbreviations since their 'usefulness' or rather
non-conflictingness depends on the actual language being used by a user.

Please consider Issue 42362
when doing a rework on abbreviations.
Comment 13 Miloslav Metelka 2004-04-28 13:32:51 UTC
We will attempt to address this into promoD.
Comment 14 janicki 2004-12-03 17:59:28 UTC
How about two abbreviation lists: one used within code, the other used within 
comments?  This would allow both standard java abbreviations as well as custom (or 
i18n localized) phrase abbreviations.

Also, I'd suggest a checkbox to enable/disable each list.  (I type fast enough to make 
most abbreviations annoying rather then helpful.  I'm learning bad habits, such as 
automatically backspacing after typing certain letter combos... this is bad when these 
habits assert themselves in other areas, e.g. my email client.  I know I should delete 
those abbreviations from the list, but a checkbox would be nice.)
Comment 15 Roman Strobl 2004-12-08 14:56:31 UTC
Changing subcomponent to macros.
Comment 16 Roman Strobl 2005-01-10 13:13:39 UTC
Changed target milestone to TBD.
Comment 17 Martin Roskanin 2005-01-21 13:42:56 UTC
*** Issue 53775 has been marked as a duplicate of this issue. ***
Comment 18 Miloslav Metelka 2005-01-27 16:20:06 UTC
I somewhat like the idea of the two abbrevs lists but I'm wondering
whether the users will be really using it in practice. Anyway
disabling of the abbrevs in comments makes sense and it could be
implemented as a simple checkbox in the abbrevs customization dialog.
Adding Rudolf to cc whether he has any comment to this.
Comment 19 Roman Strobl 2005-03-11 12:23:44 UTC
Can we fix this in 4.1? This issue was opened on nbusers and it has several
votes. If not, please remove the fix_in_41 status whiteboard, I don't insist on
fixing it till 4.1, I only suggest it. Rudolfe, do you have any comments?
Comment 20 Roman Strobl 2005-04-29 13:30:19 UTC
Removed the fix-in-41 sw while hoping we will solve important issues with
abbreviations in 4.2.
Comment 21 Miloslav Metelka 2005-05-03 14:58:56 UTC
This issue was fixed as part of the fix for issue 23138.
Comment 22 gugrim 2005-08-09 12:41:52 UTC
I've just added an enhancement request
(http://www.netbeans.org/issues/show_bug.cgi?id=61974) for the separate lists
suggested by janicki.

Comment 23 Roman Strobl 2005-10-19 12:46:20 UTC
Reopening, the issue reappeared in recent builds.
Comment 24 Miloslav Metelka 2005-10-19 16:03:13 UTC
Reopening.
Comment 25 Miloslav Metelka 2005-10-19 16:03:34 UTC
I'll fix this.
Comment 26 Miloslav Metelka 2005-10-19 16:16:05 UTC
Checking in
codetemplates/src/org/netbeans/lib/editor/codetemplates/AbbrevDetection.java;
/cvs/editor/codetemplates/src/org/netbeans/lib/editor/codetemplates/AbbrevDetection.java,v
 <--  AbbrevDetection.java
new revision: 1.4; previous revision: 1.3
done
Checking in
codetemplates/src/org/netbeans/lib/editor/codetemplates/CodeTemplateCompletionProvider.java;
/cvs/editor/codetemplates/src/org/netbeans/lib/editor/codetemplates/CodeTemplateCompletionProvider.java,v
 <--  CodeTemplateCompletionProvider.java
new revision: 1.4; previous revision: 1.3
Comment 27 Roman Strobl 2005-10-27 14:16:37 UTC
Verified.
Comment 28 klosels 2006-03-02 14:01:28 UTC
Seems to be fixed only for Java files. Problem persists with generic XML and Ant
build files.