Menu

#181 WIN32: save wgnuplot.ini to user's appdata dir

closed-accepted
None
5
2005-08-04
2005-07-07
No

This short patch changes the place where wgnuplot
saves wgnuplot.ini to the user's appdata directory.
That way every user can have his own custom
settings and saving without admin privileges will
no longer fail due to access rights.

Greetings,
Bastian

Discussion

  • Bastian Märkisch

    save wgnuplot.ini to user's appdata directoty

     
  • Hans-Bernhard Broeker

    Logged In: YES
    user_id=27517

    I like the idea, but the implementation nees more
    consideration before this can go in.

    1) Win16 target is still formally allowed to build ;-)
    2) We don't want gnuplot to be restricted to Win98+ --- but
    Win95 wouldn't necessarily support this ShellAPI call.
    3) The previous issue might be fixable by providing and
    installing the ShellAPI redistributable DLL --- but only by
    having an actual installation program instead of the current
    "unzip and run" approach. I don't think we want to go there.

    I think this means the call to this ShellAPI function has to
    be protected by run-time checks for the presence and version
    of the DLL. Any takers?

     
  • Hans-Bernhard Broeker

    • assigned_to: nobody --> broeker
     
  • Petr Mikulik

    Petr Mikulik - 2005-07-26

    Logged In: YES
    user_id=31505

    I think the patch is worth to be added.

    Comment:
    Some old "shlobj.h" do not #define CSIDL_APPDATA (e.g.
    Mingw 2.95), thus you should protect the code which sets
    textwin.IniFile by "#ifdef CSIDL_APPDATA".

     
  • Bastian Märkisch

    Logged In: YES
    user_id=1180072

    This revised version of the patch checks the version of the
    installed shell32.dll before actually using it. As a fallback
    wgnuplot.ini is saved to the user's APPDATA or HOME
    directory (taken from the environment) instead.

    So this patch no longer leaves out Win95 users, Win NT <=3.51
    is not supported.

     
  • Bastian Märkisch

    revised version

     
  • Petr Mikulik

    Petr Mikulik - 2005-08-04
    • status: open --> closed-accepted
     
  • Petr Mikulik

    Petr Mikulik - 2005-08-04

    Logged In: YES
    user_id=31505

    Committed to cvs.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.