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

List:       kde-devel
Subject:    Re: How to use KTextEditor interfaces
From:       Björn Sahlström <kbjorn () users ! sourceforge ! net>
Date:       2003-05-04 10:22:37
[Download RAW message or body]

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

fredagen den 2 maj 2003 16.44 skrev Andras Mantia:
> On Friday 2003 May 02 17:15, Björn Sahlström wrote:
> > For a ReadOnly part it's no problem, I can just
> > download the file and open it from a temp file, but for read-write I also
> > need to control the upload (when user save the file).
>
> And why can't you do the same? Download -> open in the embedded editor->on
> save upload the temporary file. You can have your own slot (called by an
> action) which calls the save method of the part.
>
> Andras

Sure I could do that and actually my version on my harddrive is watching the 
fileNameChanged() signal from Kate part and when emitted ->uploads the file. 
But for me it still is more like a workaround and workarounds always ends up 
in some sort of trouble.
The problem is that the part have its own action and slots thats merged in the 
GUI (of course ;) ) so even if I have my own slot the parts save/save as is 
called internally in the part. I could disconnect the parts methods and 
connect them to my own, but as I said it's a workaround. What I really would 
want is to make my own part inheriting KTextEditor::Editor(Kate) or something 
like  that. This inheritance should supply me with a working simple editor 
and I could just reimplement save/save as. This should give me full control. 
But maybe this isn't doable ? Isn't there an existing simple editor ready to 
use out of the box in the text editor interface ?
- -- 
MVH
Björn Sahlström
kbjorn@users.sourceforge.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE+tOnxofGrU7zTgu0RAtzfAKDm3Rs921WtWNHSVaHRs6HPCFL+2ACfTnbw
xsRNcWvbv4zRRvEi2VRLhLk=
=Dxzq
-----END PGP SIGNATURE-----

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

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

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