[Anjuta-list] Re: anjuta



"James W. Haefner" wrote:

> > Yes, I do have plan for enabling/configurable keys for the Anjuta editor.
> >
>
> good.  and I hope you don't forget us old WordStar users (don't worry, you're way too
> young to remember that venerable word"processing" program, may it rest in peace...) and do
> build in multiple escape characters...
>

I'am not that young enough to forget WS, though most of the keys have been forgotten.:-)

>
> > But if you want to configure the items given in the Anjuta menu, you can
> > very well do as follow:
> >
> > Keep  your mouse on the item which you want to configure.
> > Press the short-cut key combination.
> > You will see that the key has been changed just next to the
> > menu label. Don't worry they will be remembered in your
> > next session.
>
> very nice.  is this documented in the help?

No, because that is not part of Anjuta. It is basically Gnome that is doing that.
That means any gnome application can/will have that configurability.
Anyway, it would be a good idea to have it in anjuta manual.


>  But: How do I remove a hotkey (so that there
> is no key associated with the menu)?
>

Simple, assign the key to some other menu item. :-)


>
> Another wish list item, or request for information on how to do it:  I don't see how to
> get anjuta to look in the "data" subdirectory when I execute the program from inside
> anjuta.  I have code that reads a bunch of files. When I code w/o anjuta, I just put them
> all in the same subdirectory with the code and the executeable and it works.  But anjuta
> has this data subdirectory and I assumed that I should put those files there.  When I do
> and run the program, anjuta doesn't look there for them, nor is there a setting item to
> define where data files reside.  What was your intention for the "data" subdir?

Well, The problem of generality.

Putting your data in the src dir and using them
in your program while executing it from _that_ dir is fine. Now, what happens
if your program is installed. Installation will not take your data files with the
binary. Nor would the system execute the program from it's residing dir.

Problem is solved this way:
------------------
Do not care where data  (or pixmaps etc ..) will be installed when
your software is installed. There is no standard place where they
will go. Different systems have different places for that.

Instead, access the defined variable PACKAGE_DATA_DIR in
your program. This is the variable that is set at configure time and
tells the exact dir where your data will go. You have to include
the config.h header file generated by configure script to use it.

#include <config.h>

That was for the installed packages. What about non-installed packages.
That is, executing the package from its src dir? Well, in this case
use the defined variable PACKAGE_SOURCE_DIR. This tells
the absolute dir of the source dir. You can go any within the project
dir with is variable.

Now, the basic problem. How do the program know that it is
installed (to use PACKAGE_DATA_DIR) or not-installed
(to use PACKAGE_SOURCE_DIR)?

Simple, try PACKAGE_SOURCE_DIR first. If you
don't find the data, then try PACKAGE_DATA_DIR.
If you still don't find the data, execute: exit (-1). :-)

Or, define a macro TESTING while developing the
project. At the release time, undefine it. Now,
depending on whether this macro is defined or not,
you can use either of the dir macros.

Uhh.. rather crude way of handling data and other project files.
But that is the way when there are *so* many *standards*.
:-)

Also, you may want to peek into the file config.h generated
by configure script. There are other macros defined too.

-o-
Now, don't ask me if it is explained in the manual.
You know well it is not. Moreover, I didn't get the
time to upgrade the manual. It is still the one that
was shipped with Anjuta-0.1.1. Naturally, lot of
things do not match there. :-).

--

Regards,
-Naba

-------------------------------------------------------------
Uh-oh!!  I'm having TOO MUCH FUN!!
-------------------------------------------------------------







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]