Updated to the new naming convention

This commit is contained in:
Laurent Gomila committed 2012-03-18 10:45:20 +01:00
1 parent 9d0d0588b2
commit 36904a45d9
99 files changed
+2409 -2369

No files matched your search

+67 -67
View File
@@ -33,17 +33,17 @@
////////////////////////////////////////////////////////////
sfText* sfText_Create(void)
sfText* sfText_create(void)
{
sfText* text = new sfText;
text->Font = sfFont_GetDefaultFont();
text->Font = sfFont_getDefaultFont();
return text;
}
////////////////////////////////////////////////////////////
sfText* sfText_Copy(sfText* text)
sfText* sfText_copy(sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
@@ -52,47 +52,47 @@ sfText* sfText_Copy(sfText* text)
////////////////////////////////////////////////////////////
void sfText_Destroy(sfText* text)
void sfText_destroy(sfText* text)
{
delete text;
}
////////////////////////////////////////////////////////////
void sfText_SetPosition(sfText* text, sfVector2f position)
void sfText_setPosition(sfText* text, sfVector2f position)
{
CSFML_CALL(text, SetPosition(position.x, position.y));
CSFML_CALL(text, setPosition(position.x, position.y));
}
////////////////////////////////////////////////////////////
void sfText_SetRotation(sfText* text, float angle)
void sfText_setRotation(sfText* text, float angle)
{
CSFML_CALL(text, SetRotation(angle));
CSFML_CALL(text, setRotation(angle));
}
////////////////////////////////////////////////////////////
void sfText_SetScale(sfText* text, sfVector2f scale)
void sfText_setScale(sfText* text, sfVector2f scale)
{
CSFML_CALL(text, SetScale(scale.x, scale.y));
CSFML_CALL(text, setScale(scale.x, scale.y));
}
////////////////////////////////////////////////////////////
void sfText_SetOrigin(sfText* text, sfVector2f origin)
void sfText_setOrigin(sfText* text, sfVector2f origin)
{
CSFML_CALL(text, SetOrigin(origin.x, origin.y));
CSFML_CALL(text, setOrigin(origin.x, origin.y));
}
////////////////////////////////////////////////////////////
sfVector2f sfText_GetPosition(const sfText* text)
sfVector2f sfText_getPosition(const sfText* text)
{
sfVector2f position = {0, 0};
CSFML_CHECK_RETURN(text, position);
sf::Vector2f sfmlPos = text->This.GetPosition();
sf::Vector2f sfmlPos = text->This.getPosition();
position.x = sfmlPos.x;
position.y = sfmlPos.y;
@@ -101,19 +101,19 @@ sfVector2f sfText_GetPosition(const sfText* text)
////////////////////////////////////////////////////////////
float sfText_GetRotation(const sfText* text)
float sfText_getRotation(const sfText* text)
{
CSFML_CALL_RETURN(text, GetRotation(), 0.f);
CSFML_CALL_RETURN(text, getRotation(), 0.f);
}
////////////////////////////////////////////////////////////
sfVector2f sfText_GetScale(const sfText* text)
sfVector2f sfText_getScale(const sfText* text)
{
sfVector2f scale = {0, 0};
CSFML_CHECK_RETURN(text, scale);
sf::Vector2f sfmlScale = text->This.GetScale();
sf::Vector2f sfmlScale = text->This.getScale();
scale.x = sfmlScale.x;
scale.y = sfmlScale.y;
@@ -122,12 +122,12 @@ sfVector2f sfText_GetScale(const sfText* text)
////////////////////////////////////////////////////////////
sfVector2f sfText_GetOrigin(const sfText* text)
sfVector2f sfText_getOrigin(const sfText* text)
{
sfVector2f origin = {0, 0};
CSFML_CHECK_RETURN(text, origin);
sf::Vector2f sfmlOrigin = text->This.GetOrigin();
sf::Vector2f sfmlOrigin = text->This.getOrigin();
origin.x = sfmlOrigin.x;
origin.y = sfmlOrigin.y;
@@ -136,114 +136,114 @@ sfVector2f sfText_GetOrigin(const sfText* text)
////////////////////////////////////////////////////////////
void sfText_Move(sfText* text, sfVector2f offset)
void sfText_move(sfText* text, sfVector2f offset)
{
CSFML_CALL(text, Move(offset.x, offset.y));
CSFML_CALL(text, move(offset.x, offset.y));
}
////////////////////////////////////////////////////////////
void sfText_Rotate(sfText* text, float angle)
void sfText_rotate(sfText* text, float angle)
{
CSFML_CALL(text, Rotate(angle));
CSFML_CALL(text, rotate(angle));
}
////////////////////////////////////////////////////////////
void sfText_Scale(sfText* text, sfVector2f factors)
void sfText_scale(sfText* text, sfVector2f factors)
{
CSFML_CALL(text, Scale(factors.x, factors.y));
CSFML_CALL(text, scale(factors.x, factors.y));
}
////////////////////////////////////////////////////////////
const sfTransform* sfText_GetTransform(const sfText* text)
const sfTransform* sfText_getTransform(const sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
text->Transform.This = text->This.GetTransform();
text->Transform.This = text->This.getTransform();
return &text->Transform;
}
////////////////////////////////////////////////////////////
const sfTransform* sfText_GetInverseTransform(const sfText* text)
const sfTransform* sfText_getInverseTransform(const sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
text->InverseTransform.This = text->This.GetInverseTransform();
text->InverseTransform.This = text->This.getInverseTransform();
return &text->InverseTransform;
}
////////////////////////////////////////////////////////////
void sfText_SetString(sfText* text, const char* string)
void sfText_setString(sfText* text, const char* string)
{
CSFML_CALL(text, SetString(string));
CSFML_CALL(text, setString(string));
}
////////////////////////////////////////////////////////////
void sfText_SetUnicodeString(sfText* text, const sfUint32* string)
void sfText_setUnicodeString(sfText* text, const sfUint32* string)
{
sf::String UTF32Text = string;
CSFML_CALL(text, SetString(UTF32Text));
CSFML_CALL(text, setString(UTF32Text));
}
////////////////////////////////////////////////////////////
void sfText_SetFont(sfText* text, const sfFont* font)
void sfText_setFont(sfText* text, const sfFont* font)
{
CSFML_CHECK(font);
CSFML_CALL(text, SetFont(font->This));
CSFML_CALL(text, setFont(font->This));
text->Font = font;
}
////////////////////////////////////////////////////////////
void sfText_SetCharacterSize(sfText* text, unsigned int size)
void sfText_setCharacterSize(sfText* text, unsigned int size)
{
CSFML_CALL(text, SetCharacterSize(size));
CSFML_CALL(text, setCharacterSize(size));
}
////////////////////////////////////////////////////////////
void sfText_SetStyle(sfText* text, sfUint32 style)
void sfText_setStyle(sfText* text, sfUint32 style)
{
CSFML_CALL(text, SetStyle(style));
CSFML_CALL(text, setStyle(style));
}
////////////////////////////////////////////////////////////
void sfText_SetColor(sfText* text, sfColor color)
void sfText_setColor(sfText* text, sfColor color)
{
CSFML_CALL(text, SetColor(sf::Color(color.r, color.g, color.b, color.a)));
CSFML_CALL(text, setColor(sf::Color(color.r, color.g, color.b, color.a)));
}
////////////////////////////////////////////////////////////
const char* sfText_GetString(const sfText* text)
const char* sfText_getString(const sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
text->String = text->This.GetString().ToAnsiString();
text->String = text->This.getString().toAnsiString();
return text->String.c_str();
}
////////////////////////////////////////////////////////////
const sfUint32* sfText_GetUnicodeString(const sfText* text)
const sfUint32* sfText_getUnicodeString(const sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
return text->This.GetString().GetData();
return text->This.getString().getData();
}
////////////////////////////////////////////////////////////
const sfFont* sfText_GetFont(const sfText* text)
const sfFont* sfText_getFont(const sfText* text)
{
CSFML_CHECK_RETURN(text, NULL);
@@ -252,26 +252,26 @@ const sfFont* sfText_GetFont(const sfText* text)
////////////////////////////////////////////////////////////
unsigned int sfText_GetCharacterSize(const sfText* text)
unsigned int sfText_getCharacterSize(const sfText* text)
{
CSFML_CALL_RETURN(text, GetCharacterSize(), 0);
CSFML_CALL_RETURN(text, getCharacterSize(), 0);
}
////////////////////////////////////////////////////////////
sfUint32 sfText_GetStyle(const sfText* text)
sfUint32 sfText_getStyle(const sfText* text)
{
CSFML_CALL_RETURN(text, GetStyle(), 0);
CSFML_CALL_RETURN(text, getStyle(), 0);
}
////////////////////////////////////////////////////////////
sfColor sfText_GetColor(const sfText* text)
sfColor sfText_getColor(const sfText* text)
{
sfColor color = {0, 0, 0, 0};
CSFML_CHECK_RETURN(text, color);
sf::Color sfmlColor = text->This.GetColor();
sf::Color sfmlColor = text->This.getColor();
color.r = sfmlColor.r;
color.g = sfmlColor.g;
color.b = sfmlColor.b;
@@ -282,12 +282,12 @@ sfColor sfText_GetColor(const sfText* text)
////////////////////////////////////////////////////////////
sfVector2f sfText_FindCharacterPos(const sfText* text, size_t index)
sfVector2f sfText_findCharacterPos(const sfText* text, size_t index)
{
sfVector2f position = {0, 0};
CSFML_CHECK_RETURN(text, position);
sf::Vector2f sfmlPos = text->This.FindCharacterPos(index);
sf::Vector2f sfmlPos = text->This.findCharacterPos(index);
position.x = sfmlPos.x;
position.y = sfmlPos.y;
@@ -296,32 +296,32 @@ sfVector2f sfText_FindCharacterPos(const sfText* text, size_t index)
////////////////////////////////////////////////////////////
sfFloatRect sfText_GetLocalBounds(const sfText* text)
sfFloatRect sfText_getLocalBounds(const sfText* text)
{
sfFloatRect rect = {0, 0, 0, 0};
CSFML_CHECK_RETURN(text, rect);
sf::FloatRect sfmlRect = text->This.GetLocalBounds();
rect.Left = sfmlRect.Left;
rect.Top = sfmlRect.Top;
rect.Width = sfmlRect.Width;
rect.Height = sfmlRect.Height;
sf::FloatRect sfmlRect = text->This.getLocalBounds();
rect.left = sfmlRect.left;
rect.top = sfmlRect.top;
rect.width = sfmlRect.width;
rect.height = sfmlRect.height;
return rect;
}
////////////////////////////////////////////////////////////
sfFloatRect sfText_GetGlobalBounds(const sfText* text)
sfFloatRect sfText_getGlobalBounds(const sfText* text)
{
sfFloatRect rect = {0, 0, 0, 0};
CSFML_CHECK_RETURN(text, rect);
sf::FloatRect sfmlRect = text->This.GetGlobalBounds();
rect.Left = sfmlRect.Left;
rect.Top = sfmlRect.Top;
rect.Width = sfmlRect.Width;
rect.Height = sfmlRect.Height;
sf::FloatRect sfmlRect = text->This.getGlobalBounds();
rect.left = sfmlRect.left;
rect.top = sfmlRect.top;
rect.width = sfmlRect.width;
rect.height = sfmlRect.height;
return rect;
}