gosu 0.7.21 → 0.7.22
Sign up to get free protection for your applications and to get access to all the features.
- data/Gosu/Font.hpp +2 -1
- data/Gosu/Version.hpp +2 -2
- data/GosuImpl/Graphics/Graphics.cpp +1 -1
- data/GosuImpl/Graphics/Text.cpp +6 -4
- data/GosuImpl/RubyGosu_wrap.cxx +2 -2
- metadata +4 -4
data/Gosu/Font.hpp
CHANGED
@@ -64,7 +64,8 @@ namespace Gosu
|
|
64
64
|
#ifndef SWIG
|
65
65
|
GOSU_DEPRECATED
|
66
66
|
#endif
|
67
|
-
//! Analogous to draw, but rotates the text by a given angle.
|
67
|
+
//! DEPRECATED: Analogous to draw, but rotates the text by a given angle. Use
|
68
|
+
//! a simple pushTransform to achieve the same effect.
|
68
69
|
void drawRot(const std::wstring& text, double x, double y, ZPos z, double angle,
|
69
70
|
double factorX = 1, double factorY = 1,
|
70
71
|
Color c = Color::WHITE, AlphaMode mode = amDefault) const;
|
data/Gosu/Version.hpp
CHANGED
@@ -34,7 +34,7 @@ struct Gosu::Graphics::Impl
|
|
34
34
|
void calculateAbsoluteTransform()
|
35
35
|
{
|
36
36
|
Transform result = scale(1);
|
37
|
-
|
37
|
+
BOOST_REVERSE_FOREACH (const Transform& tf, currentTransforms)
|
38
38
|
result = multiply(result, tf);
|
39
39
|
absoluteTransforms.push_back(result);
|
40
40
|
}
|
data/GosuImpl/Graphics/Text.cpp
CHANGED
@@ -247,7 +247,8 @@ namespace Gosu
|
|
247
247
|
|
248
248
|
if (paragraph.charAt(cur) == L' ')
|
249
249
|
{
|
250
|
-
// Whitespace:
|
250
|
+
// Whitespace:
|
251
|
+
// Add last word to list if existent
|
251
252
|
if (beginOfWord != cur)
|
252
253
|
{
|
253
254
|
newWord.text = paragraph.range(beginOfWord, cur);
|
@@ -259,7 +260,8 @@ namespace Gosu
|
|
259
260
|
}
|
260
261
|
else if (isBreakingAsianGlyph(paragraph.charAt(cur)))
|
261
262
|
{
|
262
|
-
//
|
263
|
+
// Asian glyph (treat as single word):
|
264
|
+
// Add last word to list if existent
|
263
265
|
if (beginOfWord != cur)
|
264
266
|
{
|
265
267
|
newWord.text = paragraph.range(beginOfWord, cur);
|
@@ -268,7 +270,7 @@ namespace Gosu
|
|
268
270
|
collectedWords.push_back(newWord);
|
269
271
|
}
|
270
272
|
// Add glyph as a single "word"
|
271
|
-
newWord.text = paragraph.range(cur, cur +
|
273
|
+
newWord.text = paragraph.range(cur, cur + 1);
|
272
274
|
newWord.width = builder.textWidth(newWord.text);
|
273
275
|
newWord.spaceWidth = 0;
|
274
276
|
collectedWords.push_back(newWord);
|
@@ -283,7 +285,7 @@ namespace Gosu
|
|
283
285
|
lastWord.spaceWidth = 0;
|
284
286
|
collectedWords.push_back(lastWord);
|
285
287
|
}
|
286
|
-
|
288
|
+
|
287
289
|
processWords(builder, collectedWords);
|
288
290
|
}
|
289
291
|
|
data/GosuImpl/RubyGosu_wrap.cxx
CHANGED
@@ -10034,8 +10034,8 @@ SWIGEXPORT void Init_gosu(void) {
|
|
10034
10034
|
SWIG_RubyInitializeTrackings();
|
10035
10035
|
rb_define_const(mGosu, "MAJOR_VERSION", SWIG_From_int(static_cast< int >(0)));
|
10036
10036
|
rb_define_const(mGosu, "MINOR_VERSION", SWIG_From_int(static_cast< int >(7)));
|
10037
|
-
rb_define_const(mGosu, "POINT_VERSION", SWIG_From_int(static_cast< int >(
|
10038
|
-
rb_define_const(mGosu, "VERSION", SWIG_FromCharPtr("0.7.
|
10037
|
+
rb_define_const(mGosu, "POINT_VERSION", SWIG_From_int(static_cast< int >(22)));
|
10038
|
+
rb_define_const(mGosu, "VERSION", SWIG_FromCharPtr("0.7.22"));
|
10039
10039
|
rb_define_module_function(mGosu, "milliseconds", VALUEFUNC(_wrap_milliseconds), -1);
|
10040
10040
|
rb_define_module_function(mGosu, "random", VALUEFUNC(_wrap_random), -1);
|
10041
10041
|
rb_define_module_function(mGosu, "degrees_to_radians", VALUEFUNC(_wrap_degrees_to_radians), -1);
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gosu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 47
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 7
|
9
|
-
-
|
10
|
-
version: 0.7.
|
9
|
+
- 22
|
10
|
+
version: 0.7.22
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Julian Raschke
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2010-06-
|
19
|
+
date: 2010-06-17 00:00:00 +08:00
|
20
20
|
default_executable:
|
21
21
|
dependencies: []
|
22
22
|
|