Bug 321345

Summary: Show members with underscore at the end of the list available members
Product: [Developer tools] kdev-python Reporter: Roman Inflianskas <infroma>
Component: Code completionAssignee: Sven Brauch <mail>
Status: CONFIRMED ---    
Severity: wishlist CC: antonis+kdebugs
Priority: NOR    
Version First Reported In: 1.5 rc1   
Target Milestone: 1.6.0   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Bug Depends on: 206961    
Bug Blocks:    

Description Roman Inflianskas 2013-06-19 06:13:11 UTC
Hi.
This proposal is about convention "precede the variable with one underscore if it's not public API".
Suppose I have following code:
class A:
    def __init__(self):
        self._impl_member = 42
        self.normal_member = 100500
        print self.                          #  <---- auto-complete after this dot (1)

class B:
    def __init__(self):
        self.a = A()
        print self.a.                       #  <---- auto-complete after this dot (2)

I think it's quite logical that if I write class it's normal to use members with underscore, so it's OK to have them on top of the auto-completion list [see (1)], but when I access other class members they should be on the bottom on the list because normally I won't use them [see (2)]. The second behavior is not implemented.
Comment 1 Sven Brauch 2013-06-19 08:02:59 UTC
I'd like to do that, but kate doesn't allow sorting the completion list manually (it's always sorted alphabetically). So this is unfortunately on hold until I get around to add something to that interface to allow this.
Comment 2 Roman Inflianskas 2013-06-19 08:56:54 UTC
(In reply to comment #1)
> I'd like to do that, but kate doesn't allow sorting the completion list
> manually (it's always sorted alphabetically). So this is unfortunately on
> hold until I get around to add something to that interface to allow this.

Should I send feature request to Kate/KatePart bug tracker?
Comment 3 Sven Brauch 2013-06-19 09:04:42 UTC
For sorting the completion list? Sure, you can do that, but I doubt they'll implement it if it doesn't have a user :)
Comment 4 Roman Inflianskas 2013-06-19 10:31:58 UTC
(In reply to comment #3)

Found and pinned bug https://bugs.kde.org/show_bug.cgi?id=206961