navit  0.5.3-trunk
bookmarks.h File Reference

Go to the source code of this file.

Functions

struct bookmarksbookmarks_new (struct attr *parent, struct attr **attrs, struct transformation *trans)
 
void bookmarks_destroy (struct bookmarks *this_)
 
void bookmarks_add_callback (struct bookmarks *this_, struct callback *cb)
 
int bookmarks_add_bookmark (struct bookmarks *this_, struct pcoord *c, const char *description)
 
int bookmarks_cut_bookmark (struct bookmarks *this_, const char *label)
 
int bookmarks_copy_bookmark (struct bookmarks *this_, const char *label)
 
int bookmarks_paste_bookmark (struct bookmarks *this_)
 
int bookmarks_rename_bookmark (struct bookmarks *this_, const char *oldName, const char *newName)
 
int bookmarks_delete_bookmark (struct bookmarks *this_, const char *label)
 
struct mapbookmarks_get_map (struct bookmarks *this_)
 
enum projection bookmarks_get_projection (struct bookmarks *this_)
 
void bookmarks_move_root (struct bookmarks *this_)
 
void bookmarks_move_up (struct bookmarks *this_)
 
int bookmarks_move_down (struct bookmarks *this_, const char *name)
 
struct itembookmarks_get_item (struct bookmarks *this_)
 
int bookmarks_get_bookmark_count (struct bookmarks *this_)
 
void bookmarks_item_rewind (struct bookmarks *this_)
 
const char * bookmarks_item_cwd (struct bookmarks *this_)
 
char * bookmarks_get_user_data_directory (gboolean create)
 
char * bookmarks_get_destination_file (gboolean create)
 
void bookmarks_set_center_from_file (struct bookmarks *this_, char *file)
 
char * bookmarks_get_center_file (gboolean create)
 
void bookmarks_write_center_to_file (struct bookmarks *this_, char *file)
 
void bookmarks_append_destinations (struct map *former_destination_map, char *file, struct pcoord *c, int count, enum item_type type, const char *description, int limit)
 Append recent destination(s) item to the former destionations map. More...
 

Function Documentation

◆ bookmarks_add_bookmark()

◆ bookmarks_add_callback()

void bookmarks_add_callback ( struct bookmarks this_,
struct callback cb 
)

◆ bookmarks_append_destinations()

void bookmarks_append_destinations ( struct map former_destination_map,
char *  former_destination_file,
struct pcoord c,
int  count,
enum item_type  type,
const char *  description,
int  limit 
)

Append recent destination(s) item to the former destionations map.

Parameters
former_destination_map
former_destination_file
ccoordinates of item point(s). Can be set to NULL when navigation is stopped to remove type_former_itinerary and type_former_itinerary_part items from the file.
countnumber of points in this item. Set to 0 when navigation is stopped.
typetype_former_destination, type_former_itinerary and type_former_itinerary_part are meaningful here
descriptioncharacter string used to identify this destination. If NULL, most recent waypoint at these coordinates will be used to get description.
limitLimits the number of entries in the "backlog". Set to 0 for "infinite"

References _, c, description(), find_destination_in_list(), free_former_destination(), limit, map_projection(), read_former_destination_map_as_list(), transform_from_to(), type, write_former_destinations(), coord::x, pcoord::x, coord::y, and pcoord::y.

Referenced by navit_add_destination_description(), navit_set_destination(), navit_set_destinations(), and navit_vehicle_update_position().

◆ bookmarks_copy_bookmark()

◆ bookmarks_cut_bookmark()

int bookmarks_cut_bookmark ( struct bookmarks this_,
const char *  label 
)

◆ bookmarks_delete_bookmark()

◆ bookmarks_destroy()

◆ bookmarks_get_bookmark_count()

◆ bookmarks_get_center_file()

char* bookmarks_get_center_file ( gboolean  create)

◆ bookmarks_get_destination_file()

char* bookmarks_get_destination_file ( gboolean  create)
Parameters
createcreate the directory where the file is stored if it does not exist
Returns
The name of the file used to store destinations with its full path. Should be freed using g_free.

References navit_get_user_data_directory().

Referenced by navit_add_destination_description(), navit_former_destinations_active(), navit_set_destination(), navit_set_destinations(), navit_vehicle_update_position(), and read_former_destinations_from_file().

◆ bookmarks_get_item()

◆ bookmarks_get_map()

struct map* bookmarks_get_map ( struct bookmarks this_)

References bookmarks::bookmark.

Referenced by navit_get_attr().

◆ bookmarks_get_projection()

enum projection bookmarks_get_projection ( struct bookmarks this_)

◆ bookmarks_get_user_data_directory()

char* bookmarks_get_user_data_directory ( gboolean  create)

◆ bookmarks_item_cwd()

const char* bookmarks_item_cwd ( struct bookmarks this_)

◆ bookmarks_item_rewind()

◆ bookmarks_move_down()

◆ bookmarks_move_root()

◆ bookmarks_move_up()

◆ bookmarks_new()

◆ bookmarks_paste_bookmark()

◆ bookmarks_rename_bookmark()

◆ bookmarks_set_center_from_file()

void bookmarks_set_center_from_file ( struct bookmarks this_,
char *  file 
)

◆ bookmarks_write_center_to_file()

void bookmarks_write_center_to_file ( struct bookmarks this_,
char *  file 
)