/usr/include/gnucash/gnc-date-edit.h is in gnucash-common 1:2.6.12-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 | /*
* gnc-dateedit.c -- Date editor widget
*
* Copyright (C) 1997, 1998, 1999, 2000 Free Software Foundation
* All rights reserved.
*
* This file was part of the Gnome Library. It was modifed by
* Dave Peticolas <dave@krondo.com> for use in GnuCash.
*
* GnuCash is free software; you can redistribute it and/or modify
* it under the terms of the GNU Library General Public License as
* published by the Free Software Foundation; either version 2 of
* the License, or (at your option) any later version.
*
* Gnucash is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, contact:
*
* Free Software Foundation Voice: +1-617-542-5942
* 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652
* Boston, MA 02110-1301, USA gnu@gnu.org
* */
/*
@NOTATION@
*/
#ifndef GNC_DATE_EDIT_H
#define GNC_DATE_EDIT_H
#include <glib.h>
#include <time.h>
#include "gnc-date.h"
typedef enum
{
GNC_DATE_EDIT_SHOW_TIME = 1 << 0,
GNC_DATE_EDIT_24_HR = 1 << 1,
} GNCDateEditFlags;
#define GNC_TYPE_DATE_EDIT (gnc_date_edit_get_type ())
#define GNC_DATE_EDIT(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gnc_date_edit_get_type(), GNCDateEdit)
#define GNC_DATE_EDIT_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gnc_date_edit_get_type(), GNCDateEditClass)
#define GNC_IS_DATE_EDIT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gnc_date_edit_get_type ())
/**
* \verbatim
* * 2001.05.13T1647 [PDT], #gnucash:
* <jsled> dave_p: So the header for gnc-dateedit.h is a bit light
* on _why_ such a thing was done... any help?
* <dave_p> jsled: gnome date edit isn't i18n'd properly. also, we
* added the register date hotkeys.
* \endverbatim
**/
typedef struct
{
GtkHBox hbox;
GtkWidget *date_entry;
GtkWidget *date_button;
GtkWidget *time_entry;
GtkWidget *time_combo;
GtkWidget *cal_label;
GtkWidget *cal_popup;
GtkWidget *calendar;
time64 initial_time;
int lower_hour;
int upper_hour;
int flags;
int disposed;
gboolean popup_in_progress;
gboolean in_selected_handler;
} GNCDateEdit;
typedef struct
{
GtkHBoxClass parent_class;
void (*date_changed) (GNCDateEdit *gde);
void (*time_changed) (GNCDateEdit *gde);
} GNCDateEditClass;
GType gnc_date_edit_get_type (void);
GtkWidget *gnc_date_edit_new (time64 the_time,
int show_time, int use_24_format);
GtkWidget *gnc_date_edit_new_ts (Timespec the_time,
int show_time, int use_24_format);
/**
* Create a new GncDateEdit widget from a glade file. The widget
* generated is set to today's date, and will not show a time as part
* of the date. This function does not use any of the arguments
* passed by glade.
*
* @param widget_name This parameter is unused. The actual widget
* name will be set by glade so it does not need to be done here.
*
* @param string1 Unused.
* @param string2 Unused.
* @param int1 Unused.
* @param int2 Unused.
*
* @return A pointer to the newly created GncDateEdit widget.
*/
GtkWidget *gnc_date_edit_new_glade (gchar *widget_name,
gchar *string1, gchar *string2,
gint int1, gint int2);
GtkWidget *gnc_date_edit_new_flags (time64 the_time,
GNCDateEditFlags flags);
void gnc_date_edit_set_gdate (GNCDateEdit *gde, const GDate *date);
void gnc_date_edit_set_time (GNCDateEdit *gde, time64 the_time);
void gnc_date_edit_set_time_ts (GNCDateEdit *gde, Timespec the_time);
void gnc_date_edit_set_popup_range (GNCDateEdit *gde,
int low_hour, int up_hour);
void gnc_date_edit_get_gdate (GNCDateEdit *gde, GDate *date);
time64 gnc_date_edit_get_date (GNCDateEdit *gde);
Timespec gnc_date_edit_get_date_ts (GNCDateEdit *gde);
time64 gnc_date_edit_get_date_end (GNCDateEdit *gde);
Timespec gnc_date_edit_get_date_end_ts (GNCDateEdit *gde);
void gnc_date_edit_set_flags (GNCDateEdit *gde,
GNCDateEditFlags flags);
int gnc_date_edit_get_flags (GNCDateEdit *gde);
void gnc_date_activates_default (GNCDateEdit *gde, gboolean state);
void gnc_date_grab_focus (GNCDateEdit *gde);
void gnc_date_make_mnemonic_target (GNCDateEdit *gde, GtkWidget *label);
#endif
|