mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-12-22 04:02:34 +03:00
const fixes in plotters and history core
svn path=/trunk/netsurf/; revision=4083
This commit is contained in:
parent
79acb8b08c
commit
59641def82
@ -1056,7 +1056,7 @@ void urldb_set_thumbnail(const char *url, struct bitmap *bitmap)
|
||||
* \param url Absolute URL to search for
|
||||
* \return Pointer to thumbnail data, or NULL if not found.
|
||||
*/
|
||||
const struct bitmap *urldb_get_thumbnail(const char *url)
|
||||
struct bitmap *urldb_get_thumbnail(const char *url)
|
||||
{
|
||||
struct path_data *p;
|
||||
|
||||
|
@ -93,7 +93,7 @@ bool urldb_get_cert_permissions(const char *url);
|
||||
|
||||
/* Thumbnail handling */
|
||||
void urldb_set_thumbnail(const char *url, struct bitmap *bitmap);
|
||||
const struct bitmap *urldb_get_thumbnail(const char *url);
|
||||
struct bitmap *urldb_get_thumbnail(const char *url);
|
||||
|
||||
/* URL completion */
|
||||
void urldb_iterate_partial(const char *prefix,
|
||||
|
@ -225,7 +225,7 @@ void history_add(struct history *history, struct content *content,
|
||||
struct history_entry *entry;
|
||||
char *url;
|
||||
char *title;
|
||||
const struct bitmap *bitmap;
|
||||
struct bitmap *bitmap;
|
||||
|
||||
assert(history);
|
||||
assert(content);
|
||||
|
@ -55,7 +55,7 @@ static bool knockout_plot_path(float *p, unsigned int n, colour fill,
|
||||
static bool knockout_plot_fill(int x0, int y0, int x1, int y1, colour c);
|
||||
static bool knockout_plot_clip(int clip_x0, int clip_y0,
|
||||
int clip_x1, int clip_y1);
|
||||
static bool knockout_plot_text(int x, int y, struct css_style *style,
|
||||
static bool knockout_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c);
|
||||
static bool knockout_plot_disc(int x, int y, int radius, colour colour, bool filled);
|
||||
static bool knockout_plot_arc(int x, int y, int radius, int angle1, int angle2,
|
||||
@ -166,7 +166,7 @@ struct knockout_entry {
|
||||
struct {
|
||||
int x;
|
||||
int y;
|
||||
struct css_style *style;
|
||||
const struct css_style *style;
|
||||
const char *text;
|
||||
size_t length;
|
||||
colour bg;
|
||||
@ -757,7 +757,7 @@ bool knockout_plot_clip(int clip_x0, int clip_y0,
|
||||
}
|
||||
|
||||
|
||||
bool knockout_plot_text(int x, int y, struct css_style *style,
|
||||
bool knockout_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c)
|
||||
{
|
||||
knockout_entries[knockout_entry_cur].data.text.x = x;
|
||||
|
@ -40,8 +40,8 @@ struct plotter_table {
|
||||
bool (*polygon)(int *p, unsigned int n, colour fill);
|
||||
bool (*fill)(int x0, int y0, int x1, int y1, colour c);
|
||||
bool (*clip)(int x0, int y0, int x1, int y1);
|
||||
bool (*text)(int x, int y, struct css_style *style, const char *text,
|
||||
size_t length, colour bg, colour c);
|
||||
bool (*text)(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c);
|
||||
bool (*disc)(int x, int y, int radius, colour c, bool filled);
|
||||
bool (*arc)(int x, int y, int radius, int angle1, int angle2,
|
||||
colour c);
|
||||
|
@ -57,7 +57,7 @@ static bool nsgtk_plot_path(float *p, unsigned int n, colour fill, float width,
|
||||
static bool nsgtk_plot_fill(int x0, int y0, int x1, int y1, colour c);
|
||||
static bool nsgtk_plot_clip(int clip_x0, int clip_y0,
|
||||
int clip_x1, int clip_y1);
|
||||
static bool nsgtk_plot_text(int x, int y, struct css_style *style,
|
||||
static bool nsgtk_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c);
|
||||
static bool nsgtk_plot_disc(int x, int y, int radius, colour c, bool filled);
|
||||
static bool nsgtk_plot_arc(int x, int y, int radius, int angle1, int angle2,
|
||||
@ -223,7 +223,7 @@ bool nsgtk_plot_clip(int clip_x0, int clip_y0,
|
||||
}
|
||||
|
||||
|
||||
bool nsgtk_plot_text(int x, int y, struct css_style *style,
|
||||
bool nsgtk_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c)
|
||||
{
|
||||
return nsfont_paint(style, text, length, x, y, c);
|
||||
|
@ -368,7 +368,7 @@ bool nsfont_split(const struct css_style *style,
|
||||
* \return true on success, false on error and error reported
|
||||
*/
|
||||
|
||||
bool nsfont_paint(struct css_style *style, const char *string,
|
||||
bool nsfont_paint(const struct css_style *style, const char *string,
|
||||
size_t length, int x, int y, float scale)
|
||||
{
|
||||
const char *font_family;
|
||||
|
@ -208,7 +208,7 @@ void ro_gui_print_prepare(struct gui_window *g);
|
||||
void nsfont_init(void);
|
||||
bool nsfont_exists(const char *font_family);
|
||||
const char *nsfont_fallback_font(void);
|
||||
bool nsfont_paint(struct css_style *style, const char *string,
|
||||
bool nsfont_paint(const struct css_style *style, const char *string,
|
||||
size_t length, int x, int y, float scale);
|
||||
void nsfont_read_style(const struct css_style *style,
|
||||
const char **font_family, unsigned int *font_size,
|
||||
|
@ -46,7 +46,7 @@ static bool ro_plot_path(float *p, unsigned int n, colour fill, float width,
|
||||
static bool ro_plot_fill(int x0, int y0, int x1, int y1, colour c);
|
||||
static bool ro_plot_clip(int clip_x0, int clip_y0,
|
||||
int clip_x1, int clip_y1);
|
||||
static bool ro_plot_text(int x, int y, struct css_style *style,
|
||||
static bool ro_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c);
|
||||
static bool ro_plot_disc(int x, int y, int radius, colour colour, bool filled);
|
||||
static bool ro_plot_arc(int x, int y, int radius, int angle1, int angle2,
|
||||
@ -395,7 +395,7 @@ bool ro_plot_clip(int clip_x0, int clip_y0,
|
||||
}
|
||||
|
||||
|
||||
bool ro_plot_text(int x, int y, struct css_style *style,
|
||||
bool ro_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c)
|
||||
{
|
||||
os_error *error;
|
||||
|
@ -106,7 +106,7 @@ static bool print_fonts_plot_polygon(int *p, unsigned int n, colour fill);
|
||||
static bool print_fonts_plot_fill(int x0, int y0, int x1, int y1, colour c);
|
||||
static bool print_fonts_plot_clip(int clip_x0, int clip_y0,
|
||||
int clip_x1, int clip_y1);
|
||||
static bool print_fonts_plot_text(int x, int y, struct css_style *style,
|
||||
static bool print_fonts_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c);
|
||||
static bool print_fonts_plot_disc(int x, int y, int radius, colour c,
|
||||
bool filled);
|
||||
@ -843,7 +843,7 @@ bool print_fonts_plot_group_end(void) { return true; }
|
||||
* Plotter for text plotting during font listing.
|
||||
*/
|
||||
|
||||
bool print_fonts_plot_text(int x, int y, struct css_style *style,
|
||||
bool print_fonts_plot_text(int x, int y, const struct css_style *style,
|
||||
const char *text, size_t length, colour bg, colour c)
|
||||
{
|
||||
const char *font_family;
|
||||
|
Loading…
Reference in New Issue
Block a user