[gnomemm] Re: gnome2: calling gnome_help_display() fails



Hi Vladislav,
Passing GNOME_PROGRAM_STANDARD_PROPERTIES to gnome_program_init()
should work. (I mean whatever Rodrigo has suggested should work
fine).

Make sure the "app-id" you are passing in program_init() should
match with your help file name. The help document should be named
as app-id.xml. (Are your help files are getting installed in the
proper location . It should be present
prefix/share/gnome/help/<app-name>/<locale>/<app-id>.xml

Actually you only need to send the DATADIR to program_init() to make
the application search the help file. (GNOME_PROGRAM_STANDARD_PROPERTIES
does the thing also).

Try this way and let me know if it works. I have modified many of the gnome apps
this way and they continue to work :)

Change in Makefile.am

SUBDIRS = help
INCLUDES = \
+       -DDATADIR=\""$(datadir)"\"


Change gnome_program_init() to pass the DATDIR

gnome_program_init (app_id, version, LIBGNOMEUI_MODULE, nargs, args,
                    GNOME_PARAM_APP_DATADIR,DATADIR,NULL);


Thanks
Satyajit


Vladislav Grinchenko wrote:
Rodrigo,

thanks for advice. I modified my Makefile.am to include defines below
and used GNOME_PROGRAM_STANDARD_PROPERTIES, with the same result - no
dice.

BTW, it doesn't look like I can pass GNOME_PROGRAM_STANDARD_PROPERTIES
to either of Gnome::Main () constructors. I went ahead and modified
libgnomemm's code to do so, but, again with no visible result.

Any other ideas to try?


On Sun, 2003-01-26 at 08:08, Rodrigo Moya wrote:

On Sun, 2003-01-26 at 05:20, Vladislav Grinchenko wrote:

Hi,

I've been struggling with this for about a week.
In my gnome2 (gnomemm2) application, call to gnome_help_display() fails
with:

Gnome-WARNING **: gnome-program.c:986: Directory properties not set
correctly.  Cannot locate application specific files.


when you call gnome_program_init, do it this way:

gnome_program_init (app_id, version, LIBGNOMEUI_MODULE, nargs, args,
                           GNOME_PROGRAM_STANDARD_PROPERTIES, NULL);

this will add the need for adding some -D to the compilation command
line, since GNOME_PROGRAM_STANDARD_PROPERTIES expects them to be
defined. They are:

	-DPREFIX=\""$(prefix)"\" \
       -DSYSCONFDIR=\""$(sysconfdir)"\" \
       -DDATADIR=\""$(datadir)"\" \
       -DLIBDIR=\""$(libdir)"\"

once you do this, gnome_help_display knows how to find the help file. At
least, it did work for me.

cheers

_______________________________________________
gnome-doc-list mailing list
gnome-doc-list gnome org
http://mail.gnome.org/mailman/listinfo/gnome-doc-list



_______________________________________________
gnome-devel-list mailing list
gnome-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gnome-devel-list






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