Blame rdtk/include/rdtk/rdtk.h

Packit 1fb8d4
/**
Packit 1fb8d4
 * RdTk: Remote Desktop Toolkit
Packit 1fb8d4
 *
Packit 1fb8d4
 * Copyright 2014 Marc-Andre Moreau <marcandre.moreau@gmail.com>
Packit 1fb8d4
 *
Packit 1fb8d4
 * Licensed under the Apache License, Version 2.0 (the "License");
Packit 1fb8d4
 * you may not use this file except in compliance with the License.
Packit 1fb8d4
 * You may obtain a copy of the License at
Packit 1fb8d4
 *
Packit 1fb8d4
 *     http://www.apache.org/licenses/LICENSE-2.0
Packit 1fb8d4
 *
Packit 1fb8d4
 * Unless required by applicable law or agreed to in writing, software
Packit 1fb8d4
 * distributed under the License is distributed on an "AS IS" BASIS,
Packit 1fb8d4
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Packit 1fb8d4
 * See the License for the specific language governing permissions and
Packit 1fb8d4
 * limitations under the License.
Packit 1fb8d4
 */
Packit 1fb8d4
Packit 1fb8d4
#ifndef RDTK_H
Packit 1fb8d4
#define RDTK_H
Packit 1fb8d4
Packit 1fb8d4
#include <rdtk/api.h>
Packit 1fb8d4
Packit 1fb8d4
#include <winpr/crt.h>
Packit 1fb8d4
#include <winpr/windows.h>
Packit 1fb8d4
Packit 1fb8d4
#include <freerdp/codec/color.h>
Packit 1fb8d4
#include <freerdp/codec/region.h>
Packit 1fb8d4
Packit 1fb8d4
typedef struct rdtk_engine rdtkEngine;
Packit 1fb8d4
typedef struct rdtk_font rdtkFont;
Packit 1fb8d4
typedef struct rdtk_glyph rdtkGlyph;
Packit 1fb8d4
typedef struct rdtk_surface rdtkSurface;
Packit 1fb8d4
typedef struct rdtk_button rdtkButton;
Packit 1fb8d4
typedef struct rdtk_label rdtkLabel;
Packit 1fb8d4
typedef struct rdtk_text_field rdtkTextField;
Packit 1fb8d4
typedef struct rdtk_nine_patch rdtkNinePatch;
Packit 1fb8d4
Packit 1fb8d4
#ifdef __cplusplus
Packit Service 5a9772
extern "C"
Packit Service 5a9772
{
Packit 1fb8d4
#endif
Packit 1fb8d4
Packit Service 5a9772
	/* Engine */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT rdtkEngine* rdtk_engine_new();
Packit Service 5a9772
	RDTK_EXPORT void rdtk_engine_free(rdtkEngine* engine);
Packit 1fb8d4
Packit Service 5a9772
	/* Surface */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT int rdtk_surface_fill(rdtkSurface* surface, int x, int y, int width, int height,
Packit Service 5a9772
	                                  UINT32 color);
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT rdtkSurface* rdtk_surface_new(rdtkEngine* engine, BYTE* data, int width, int height,
Packit Service 5a9772
	                                          int scanline);
Packit Service 5a9772
	RDTK_EXPORT void rdtk_surface_free(rdtkSurface* surface);
Packit 1fb8d4
Packit Service 5a9772
	/* Font */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT int rdtk_font_draw_text(rdtkSurface* surface, int nXDst, int nYDst, rdtkFont* font,
Packit Service 5a9772
	                                    const char* text);
Packit 1fb8d4
Packit Service 5a9772
	/* Button */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT int rdtk_button_draw(rdtkSurface* surface, int nXDst, int nYDst, int nWidth,
Packit Service 5a9772
	                                 int nHeight, rdtkButton* button, const char* text);
Packit 1fb8d4
Packit Service 5a9772
	/* Label */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT int rdtk_label_draw(rdtkSurface* surface, int nXDst, int nYDst, int nWidth,
Packit Service 5a9772
	                                int nHeight, rdtkLabel* label, const char* text, int hAlign,
Packit Service 5a9772
	                                int vAlign);
Packit 1fb8d4
Packit Service 5a9772
	/* TextField */
Packit 1fb8d4
Packit Service 5a9772
	RDTK_EXPORT int rdtk_text_field_draw(rdtkSurface* surface, int nXDst, int nYDst, int nWidth,
Packit Service 5a9772
	                                     int nHeight, rdtkTextField* textField, const char* text);
Packit 1fb8d4
Packit 1fb8d4
#ifdef __cplusplus
Packit 1fb8d4
}
Packit 1fb8d4
#endif
Packit 1fb8d4
Packit 1fb8d4
#endif /* RDTK_H */