Freeciv-3.2
Loading...
Searching...
No Matches
canvas_g.h
Go to the documentation of this file.
1/***********************************************************************
2 Freeciv - Copyright (C) 1996-2005 - Freeciv Development Team
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12***********************************************************************/
13#ifndef FC__CANVAS_G_H
14#define FC__CANVAS_G_H
15
16#include "support.h" /* bool type */
17
19
20struct color;
21struct sprite;
22
23struct canvas; /* Opaque type, real type is gui-dep */
24
28
29/* Creator and destructor */
31GUI_FUNC_PROTO(void, canvas_free, struct canvas *store)
32
33GUI_FUNC_PROTO(void, canvas_set_zoom, struct canvas *store, float zoom)
35
37
38/* Drawing functions */
40 int src_x, int src_y, int dest_x, int dest_y,
41 int width, int height)
44 int offset_x, int offset_y, int width, int height);
46 int canvas_x, int canvas_y,
49 int canvas_x, int canvas_y, int canvas_w, int canvas_h,
52 int canvas_x, int canvas_y,
54 bool fog, int fog_x, int fog_y)
57 int canvas_x, int canvas_y, int width, int height)
61 int canvas_x, int canvas_y)
64 enum line_type ltype, int start_x, int start_y,
65 int dx, int dy)
68 enum line_type ltype, int start_x, int start_y,
69 int dx, int dy)
70
71/* Text drawing functions */
77};
79 enum client_font font, const char *text)
81 int canvas_x, int canvas_y, enum client_font font,
82 struct color *pcolor, const char *text)
83
84#endif /* FC__CANVAS_G_H */
struct canvas int int struct sprite int int int int height
Definition canvas_g.h:44
struct canvas int int int int struct sprite *sprite struct canvas struct color * pcolor
Definition canvas_g.h:56
struct canvas int int int int struct sprite *sprite canvas_put_rectangle
Definition canvas_g.h:55
struct canvas int int canvas_y
Definition canvas_g.h:43
struct canvas int canvas_x
Definition canvas_g.h:43
struct canvas int int int int struct sprite *sprite struct canvas struct color int int int int height canvas_put_line
Definition canvas_g.h:62
canvas_put_sprite
Definition canvas_g.h:42
struct canvas int int int canvas_w
Definition canvas_g.h:49
struct canvas int int int int canvas_h
Definition canvas_g.h:49
struct canvas * pcanvas
Definition canvas_g.h:42
canvas_put_sprite_full_scaled
Definition canvas_g.h:48
canvas_put_text
Definition canvas_g.h:80
struct canvas int int struct sprite int int offset_y
Definition canvas_g.h:44
struct canvas int int struct sprite int offset_x
Definition canvas_g.h:44
struct canvas int int struct sprite int int int width
Definition canvas_g.h:44
line_type
Definition canvas_g.h:25
@ LINE_SELECT_RECT
Definition canvas_g.h:26
@ LINE_GOTO
Definition canvas_g.h:26
@ LINE_TILE_FRAME
Definition canvas_g.h:26
@ LINE_BORDER
Definition canvas_g.h:26
@ LINE_NORMAL
Definition canvas_g.h:26
char * incite_cost
Definition comments.c:75
void canvas_put_sprite_full(struct canvas *pcanvas, int canvas_x, int canvas_y, struct sprite *sprite)
Definition canvas.c:144
void canvas_set_zoom(struct canvas *store, float zoom)
Definition canvas.c:53
void canvas_mapview_init(struct canvas *store)
Definition canvas.c:69
void canvas_fill_sprite_area(struct canvas *pcanvas, struct sprite *psprite, struct color *pcolor, int canvas_x, int canvas_y)
Definition canvas.c:211
void get_text_size(int *width, int *height, enum client_font font, const char *text)
Definition canvas.c:341
void canvas_free(struct canvas *store)
Definition canvas.c:44
void canvas_put_curved_line(struct canvas *pcanvas, struct color *pcolor, enum line_type ltype, int start_x, int start_y, int dx, int dy)
Definition canvas.c:276
bool has_zoom_support(void)
Definition canvas.c:61
void canvas_copy(struct canvas *dest, struct canvas *src, int src_x, int src_y, int dest_x, int dest_y, int width, int height)
Definition canvas.c:76
struct canvas * canvas_create(int width, int height)
Definition canvas.c:28
void canvas_put_sprite_fogged(struct canvas *pcanvas, int canvas_x, int canvas_y, struct sprite *psprite, bool fog, int fog_x, int fog_y)
Definition canvas.c:170
#define GUI_FUNC_PROTO(_type, _func,...)
float zoom
Definition canvas.h:25
Definition colors.h:21