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

List:       kdevelop-bugs
Subject:    [Bug 302491] New: Some features which, in my opinion, miss in the interface dbus of kdevelop
From:       Georges Lours <geo.lours () free ! fr>
Date:       2012-06-25 8:06:42
Message-ID: bug-302491-40295 () http ! bugs ! kde ! org/
[Download RAW message or body]

https://bugs.kde.org/show_bug.cgi?id=302491

            Bug ID: 302491
          Severity: wishlist
           Version: 4.3.0
          Priority: NOR
          Assignee: kdevelop-bugs@kdevelop.org
           Summary: Some features which, in my opinion, miss in the
                    interface dbus of kdevelop
    Classification: Unclassified
                OS: Linux
          Reporter: geo.lours@free.fr
          Hardware: Fedora RPMs
            Status: UNCONFIRMED
         Component: all editors
           Product: kdevelop

I try to write a script bash which inserts characters' strings into an opened
document in kdevelop. When we had kde 3.x, I had succeeded in making something
similar with quanta 3.x and dcop. But now, I try to use kdevelop...
NB except one about set cursor position (cf. second problem), all these
problems are common with kate application.

First problem

I did not find a dbus method which allows to detect the active document (when
several are opened in various tabs) neither in kate, nor in kdevelop.
In quanta 3.x and dcop, I used:
-----------------------
num=$(dcop `dcop | grep quanta` WindowManagerIf currentEditorIfNum)
-----------------------
Would it be possible to have a similar function for kdevelop?

Second problem

How to locate the cursor position in my document kdevelop?
It use to exist with quanta 3.x and dcop
-----------------------
col=$(dcop `dcop | grep quanta` ViewCursorInterface#$num-$num cursorColumn)
line=$(dcop `dcop | grep quanta` ViewCursorInterface#$num-$num cursorLine)
(where num is a corresponding variable to the document I want to treat(handle)
in kdevelop - cf first problem)
-----------------------
Would it be possible to have a similar function for kdevelop?
NB: Still about the cursor, there is a dbus command which exists for kate, but
not for kdevelop to place the cursor where I wish it to be.
-----------------------
qdbus `qdbus | grep kate` /MainApplication org.kde.Kate.Application.setCursor
$line $col
-----------------------
Is it possible to have the same with kdevelop too?

Third problem

Is there a method allowing to erase the selected part of the active document?
and to replace it?
With quanta 3.x and dcop, I used this :
-----------------------
dcop `dcop | grep quanta` SelectionInterface#$num removeSelectedText
-----------------------
and when I had a new content in clipboard
-----------------------
dcop `dcop | grep quanta` "ClipboardInterface#$num-$num" paste
-----------------------
Would it be possible to have a similar function for kdevelop?

Fourth problem

I'm not able to manage to make the method insertText work
-----------------------
$ qdbus `qdbus | grep kdevelop` /Kate/Document/$num |grep insertText
method bool org.kde.KTextEditor.Document.insertText(QDBusRawType::(ii cursor)
method bool org.kde.KTextEditor.Document.insertTextLines(QDBusRawType::(ii
cursor)
(where num is a corresponding variable to the document I want to treat(handle)
in kdevelop - cf first problem)
-----------------------
I have the same problem with the method cursorInText
-----------------------
$ qdbus `qdbus | grep kdevelop` /Kate/Document/$num |grep cursorInText
method bool org.kde.KTextEditor.Document.cursorInText(QDBusRawType::(ii cursor)
-----------------------
How must i write the parameters of the cursor? I believe to have tried
everything, and nothing works...

Reproducible: Always

-- 
You are receiving this mail because:
You are the assignee for the bug.

_______________________________________________
KDevelop-bugs mailing list
KDevelop-bugs@kdevelop.org
https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-bugs
[prev in list] [next in list] [prev in thread] [next in thread] 

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