new KDevPlatform API for consideration

Hamish Rodda rodda at kde.org
Fri May 26 08:16:43 UTC 2006


On Friday 26 May 2006 14:35, Matt Rogers wrote:
> On Thursday 25 May 2006 10:53, Andras Mantia wrote:
> > On Wednesday 24 May 2006 15:12, Matt Rogers wrote:
> > > On Wednesday 24 May 2006 05:44, Andras Mantia wrote:
> > > > On Wednesday 24 May 2006 05:16, Matt Rogers wrote:
> > > > > hmmm, no, absoluteUrl and relativeUrl should be removed perhaps.
> > > > > They seem completely useless ATM.
> > > >
> > > > Jumping in.. There is a need to calculate/convert urls to
> > > > absolute/relative urls based on the "project base".
> > > >
> > > > Andras
> > >
> > > use cases?
> >
> > Well, for example we store the relative URL to the project base for each
> > project file. I know for KDevelop it's KDevelop2 days, but we don't
> > have files belonging to a build system describing what is in the
> > project and what is not, so we list all files in the project file and
> > assign some attributes to them. Similar thing will be required once
> > David starts the teamwork mode support, as notes and such have to be
> > associated to project files.
> > So whenever you add a file to a project, the relative url based on the
> > project base is stored in the project file. When you access it (eg.
> > upload), the URL is converted to an absolute one so it can be passed to
> > KIO.
>
> So... what if you branched out a bit, and try to realize how using the
> project manager importers and the file manager can help you from not having
> to keep that list. For example, there is a generic importer already in
> trunk/KDE/kdevelop/buildtools/importers/generic that, at the moment, only
> takes C & C++ files, but i'm sure it could be extended and enhanced to use
> the mimetypes that are supported by the language support parts of the
> project. We could also extend it such that it would use KDirLister to look
> for new files and automatically add them to the project (if so desired)
>
> Please try to start thinking out of the box a bit about how your current
> code can be adapted to these new ideas rather than just keeping in line
> with what you already have. The ultimate goal of the file managers is so
> that you don't have to store file lists in the project file or in some
> separate file.
>
> > relative/absolute URL handling is needed in other cases as well, like
> > when inserting a link/image into a file.
>
> Sure, I won't dispute that, but is that really something that should be
> part of KDevProject?

I don't see the reason why not to have one or more base URLs; in memory, we 
keep the absolute URLs for files, and on save/load load they get converted 
to/from relative URLs if desired.  This would fit within the scope of 
KDevProject imho.  Just as long as we get rid of in-memory relative URLs.

Cheers,
Hamish.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20060526/719d6f67/attachment.sig>


More information about the KDevelop-devel mailing list