Back to index

lightning-sunbird  0.9+nobinonly
Classes | Typedefs | Functions
cairo-path-bounds.c File Reference
#include "cairoint.h"

Go to the source code of this file.

Classes

struct  cairo_path_bounder

Typedefs

typedef struct cairo_path_bounder cairo_path_bounder_t

Functions

static void _cairo_path_bounder_init (cairo_path_bounder_t *bounder)
static void _cairo_path_bounder_fini (cairo_path_bounder_t *bounder)
static cairo_status_t _cairo_path_bounder_add_point (cairo_path_bounder_t *bounder, cairo_point_t *point)
static cairo_status_t _cairo_path_bounder_move_to (void *closure, cairo_point_t *point)
static cairo_status_t _cairo_path_bounder_line_to (void *closure, cairo_point_t *point)
static cairo_status_t _cairo_path_bounder_curve_to (void *closure, cairo_point_t *b, cairo_point_t *c, cairo_point_t *d)
static cairo_status_t _cairo_path_bounder_close_path (void *closure)
cairo_status_t _cairo_path_fixed_bounds (cairo_path_fixed_t *path, double *x1, double *y1, double *x2, double *y2)

Class Documentation

struct cairo_path_bounder

Definition at line 39 of file cairo-path-bounds.c.

Collaboration diagram for cairo_path_bounder:
Class Members
int has_point
cairo_fixed_t max_x
cairo_fixed_t max_y
cairo_fixed_t min_x
cairo_fixed_t min_y

Typedef Documentation


Function Documentation

Definition at line 85 of file cairo-path-bounds.c.

{
    if (bounder->has_point) {
       if (point->x < bounder->min_x)
           bounder->min_x = point->x;
       
       if (point->y < bounder->min_y)
           bounder->min_y = point->y;
       
       if (point->x > bounder->max_x)
           bounder->max_x = point->x;
       
       if (point->y > bounder->max_y)
           bounder->max_y = point->y;
    } else {
       bounder->min_x = point->x;
       bounder->min_y = point->y;
       bounder->max_x = point->x;
       bounder->max_y = point->y;

       bounder->has_point = 1;
    }
       
    return CAIRO_STATUS_SUCCESS;
}

Here is the caller graph for this function:

static cairo_status_t _cairo_path_bounder_close_path ( void closure) [static]

Definition at line 147 of file cairo-path-bounds.c.

Here is the caller graph for this function:

static cairo_status_t _cairo_path_bounder_curve_to ( void closure,
cairo_point_t b,
cairo_point_t c,
cairo_point_t d 
) [static]

Definition at line 132 of file cairo-path-bounds.c.

Here is the call graph for this function:

Here is the caller graph for this function:

static void _cairo_path_bounder_fini ( cairo_path_bounder_t bounder) [static]

Definition at line 79 of file cairo-path-bounds.c.

{
    bounder->has_point = 0;
}

Here is the caller graph for this function:

static void _cairo_path_bounder_init ( cairo_path_bounder_t bounder) [static]

Definition at line 73 of file cairo-path-bounds.c.

{
    bounder->has_point = 0;
}

Here is the caller graph for this function:

static cairo_status_t _cairo_path_bounder_line_to ( void closure,
cairo_point_t point 
) [static]

Definition at line 122 of file cairo-path-bounds.c.

Here is the call graph for this function:

Here is the caller graph for this function:

static cairo_status_t _cairo_path_bounder_move_to ( void closure,
cairo_point_t point 
) [static]

Definition at line 112 of file cairo-path-bounds.c.

Here is the call graph for this function:

Here is the caller graph for this function:

cairo_status_t _cairo_path_fixed_bounds ( cairo_path_fixed_t *  path,
double *  x1,
double *  y1,
double *  x2,
double *  y2 
)

Definition at line 154 of file cairo-path-bounds.c.

Here is the call graph for this function: