[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-bindings
Subject:    Re: [Kde-bindings] classes in the KTextEditor namespace don't seem
From:       Richard Dale <rdale () foton ! es>
Date:       2010-01-26 13:21:50
Message-ID: 201001261321.50939.rdale () foton ! es
[Download RAW message or body]

On Tuesday 26 January 2010 07:43:10 am Stefano Crocco wrote:
> I may have my system messed up regarding kdebindings, so the problem I'm
> speaking about may be only caused by this. However, I just finished
>  installing the latest svn revision of smoke and korundum from the 4.4
>  branch, and it seems that there's something wrong with KTextEditor (using
>  ruby 1.9, if it matters). KTextEditor.constants only returns [:Internal],
>  while with an old svn revision of smoke/korundum it returns a full list of
>  class names, such as
> 
> :Document, :View and so on. Accordingly, with the new version, my program
> 
> fails as soon as it tries to access the KTextEditor::AnnotationModel class.
> 
> As I've said, it can easily be some problem on my system, but I'm writing
>  this mail all the same so that the developers can be aware of the problem,
>  just in case it actually is a problem.
Yes, it was a bug and should be fixed now. At the moment each module provides a 
'normalization_proc' which is responsible for class renaming. However, all 
normalization procs are applied to all classes. As the Korundum normalization 
proc doesn't know about any classes whose names begin with 'K' outside its 
extension, it just assumes they want renaming. So KTextEditor gets renamed as 
KDE::TextEditor and so on. I've hacked the Korundum extension ruby code so 
that it knows about the KParts:: and KTextEditor:: classes, but that isn't 
very modular.

The proper solution is to do the class renaming in the extension's C++ code as 
it reads the list of classes from the Smoke module. That will be how it will 
work for the KDE 4.5 release.

-- Richard
_______________________________________________
Kde-bindings mailing list
Kde-bindings@kde.org
https://mail.kde.org/mailman/listinfo/kde-bindings
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic