Bug 102316 - tools->comment functionality broken for cpp files
Summary: tools->comment functionality broken for cpp files
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: part (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-23 21:56 UTC by Holger Schröder
Modified: 2010-11-06 22:25 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 4.5.4
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Holger Schröder 2005-03-23 21:56:17 UTC
Version:           3.2.0 (using KDE 3.4.0, Gentoo)
Compiler:          gcc version 3.3.5 (Gentoo Linux 3.3.5-r1, ssp-3.3.2-3, pie-8.7.7.1)
OS:                Linux (i686) release 2.6.9-gentoo-r1

Hi,

with older versions of kdevelop i could mark some text lines and then choose tools->comment and the marked text would then be commented. i used this to quickly comment out stuff, that i wanted to disable. now this dows not work any more.

for example when i have these few lines in a cpp file:


    /**
     * @return the configured server login;
     */



and mark them, and then choose tools->comment (or the corresponding shortcut) nothing happens.

is my local config messed up, or is this intended behaviour or is this a bug ?

i am missing this feature ;-)

regards, Holger
Comment 1 Jens Dagerbo 2005-03-24 13:10:29 UTC
That feature is a function of the embedded editor (in this case, Katepart). Try it in Kate/KWrite - Do you see the same behaviour?
Comment 2 Holger Schröder 2005-03-24 13:31:20 UTC
yes, kate shows the same behaviour, so this bug should be assigned to kate, 
right ?

Holger

On Thursday 24 March 2005 13:10, Jens Dagerbo wrote:
[bugs.kde.org quoted mail]
Comment 3 Anders Lund 2005-10-30 22:20:47 UTC
In c++, the text

/**
 * bla
 */

*is* a comment, so kate silently ignores the request to make it one. Why on earth is that a bug??
Comment 4 Holger Schröder 2005-10-31 13:56:50 UTC
well, when you want to comment a block of code, which contains some "normal" c or c++ comments, like

if ( i < 0 )
{
    // return here
    return;
    /* 
    some other comment
    */
}

you can simply mark the whole block and comment it out by pressing ctrl-d. we use this quite often when editing cpp files in kate/kdevelop.

it is quite confusing, that this does not work, when doxygen comments are included in the code that you want to comment out. i think this is a bug or at least a missing functionality.
Comment 5 Anders Lund 2005-10-31 16:40:18 UTC
It does not work if you try to comment a doxygen comment and nothing else. Whereas you can comment a multiline cpp comment and nothing else. I agree that that is silly and should be fixed.

Dominik: anotherusage for isCommentAttrib() ;)
Comment 6 Pascal Létourneau 2010-11-06 20:29:49 UTC
SVN commit 1193691 by pletourn:

Don't use the attribute of the end
since the end will be commented

BUG:102316


 M  +4 -9      katedocument.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1193691
Comment 7 Pascal Létourneau 2010-11-06 20:31:26 UTC
SVN commit 1193692 by pletourn:

Don't use the attribute of the end
since the end will be commented

BUG:102316


 M  +4 -9      katedocument.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1193692