Sha256: da5d99c5b65df0231a7edf5ef1378ad4c99772766251888d925bebb2ccc01f6b

Contents?: true

Size: 1019 Bytes

Versions: 24

Compression:

Stored size: 1019 Bytes

Contents

// -*- c++ -*-
#pragma once
#ifndef __RAYS_SRC_FONT_H__
#define __RAYS_SRC_FONT_H__


#include <rays/defs.h>
#include <rays/font.h>


namespace Rays
{


	class RawFont
	{

		public:

			RawFont ();

			RawFont (const char* name, coord size = 0);

			~RawFont ();

			void draw_string (
				void* context, coord context_height,
				const char* str, coord x, coord y) const;

			String name () const;

			coord size () const;

			coord get_width (const char* str) const;

			coord get_height (
				coord* ascent  = NULL,
				coord* descent = NULL,
				coord* leading = NULL) const;

			operator bool () const;

			bool operator ! () const;

			struct Data;

			Xot::PSharedImpl<Data> self;

	};// RawFont


	const RawFont& Font_get_raw (const Font& font, float pixel_density);

	coord Font_get_width (const Font& font, float pixel_density, const char* str);

	coord Font_get_height (
		const Font& font, float pixel_density,
		coord* ascent = NULL, coord* descent = NULL, coord* leading = NULL);


}// Rays


#endif//EOH

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
rays-0.1.36 src/font.h
rays-0.1.35 src/font.h
rays-0.1.34 src/font.h
rays-0.1.33 src/font.h
rays-0.1.32 src/font.h
rays-0.1.31 src/font.h
rays-0.1.30 src/font.h
rays-0.1.29 src/font.h
rays-0.1.28 src/font.h
rays-0.1.27 src/font.h
rays-0.1.26 src/font.h
rays-0.1.25 src/font.h
rays-0.1.24 src/font.h
rays-0.1.23 src/font.h
rays-0.1.22 src/font.h
rays-0.1.21 src/font.h
rays-0.1.20 src/font.h
rays-0.1.19 src/font.h
rays-0.1.18 src/font.h
rays-0.1.17 src/font.h