xfce_rc_delete_entry not working

juha kautto.juha at kolumbus.fi
Mon Apr 17 16:34:51 CEST 2006


Benedikt Meurer wrote:

>juha wrote:
>  
>
>>Hi !
>>
>>I thought that xfce_rc_delete_entry would have caused
>>the key to vanish from the rc file. But that is not
>>happening. Is that known bug? or did I misunderstood
>>this? It is not possible to remove entries written with
>>xfce_rc_write_entry?
>>    
>>
>
>How do you use the function? On an XfceRc opened with
>xfce_rc_simple_open() or xfce_rc_config_open()?
>  
>
I use 

xfce_rc_simple_open() 

 like this:
...
static void oc_write_rc_file(XfcePanelPlugin *plugin, Clock *clock)
{
    gchar  *file;
    XfceRc *rc;
    gchar   tmp[100];

    if (!(file = xfce_panel_plugin_save_location(plugin, TRUE)))
        return;

    rc = xfce_rc_simple_open(file, FALSE);
    g_free(file);

    if (!rc)
        return;

    xfce_rc_write_bool_entry(rc, "fg_set", clock->fg_set);
    if (clock->fg_set) {
        sprintf(tmp, "%uR %uG %uB"
                , clock->fg.red, clock->fg.green, clock->fg.blue);
        xfce_rc_write_entry(rc, "fg", tmp);
    }
    else {
        *xfce_rc_delete_entry*(rc, "fg", TRUE);
    }


    xfce_rc_close(rc);
}
...

>  
>
>>Is there any 4.3 level documentation od these functions?
>>    
>>
>
>The usual API docs
>
>http://www.xfce.org/documentation/api-4.4/libxfce4util/libxfce4util-Resource-Config-File-Support.html
>
>but XfceRc function did not really change since 4.2, except for a few
>bugfixes.
>  
>
Thanks. for the pointer.
I think this function did not work in 4.2 either.
I also tried adding groups, but that did not help.

>  
>
>>/Juha
>>    
>>
>
>Benedikt
>_______________________________________________
>Xfce4-dev mailing list
>Xfce4-dev at xfce.org
>http://foo-projects.org/mailman/listinfo/xfce4-dev
>  
>




More information about the Xfce4-dev mailing list