Lenard Lindstrom avatar Lenard Lindstrom committed 2bf1275

changeset d2feb84c6b76 broke freetype_misc.py example, fix

Comments (0)

Files changed (1)

examples/freetype_misc.py

     font.underline_adjustment = 0.5
     font.pad = True
     font.render_to(screen, (32, 32), "Hello World", colors["red"],
-                   colors['grey_dark'], ptsize=64,
+                   colors['grey_dark'], size=64,
                    style=freetype.STYLE_UNDERLINE|freetype.STYLE_OBLIQUE)
     font.pad = False
 
     font.render_to(screen, (32, 128), "abcdefghijklm", colors["grey_dark"],
-                   colors["green"], ptsize=64)
+                   colors["green"], size=64)
 
     font.vertical = True
     font.render_to(screen, (32, 200), "Vertical?", colors["blue"],
-                   None, ptsize=32)
+                   None, size=32)
     font.vertical = False
 
     font.render_to(screen, (64, 190), "Let's spin!", colors["red"],
-                   None, ptsize=48, rotation=55)
+                   None, size=48, rotation=55)
 
     font.render_to(screen, (160, 290), "All around!", colors["green"],
-                   None, ptsize=48, rotation=-55)
+                   None, size=48, rotation=-55)
 
     font.render_to(screen, (250, 220), "and BLEND",
-                   pygame.Color(255, 0, 0, 128), None, ptsize=64)
+                   pygame.Color(255, 0, 0, 128), None, size=64)
 
     font.render_to(screen, (265, 237), "or BLAND!",
-                   pygame.Color(0, 0xCC, 28, 128), None, ptsize=64)
+                   pygame.Color(0, 0xCC, 28, 128), None, size=64)
 
     # Some pinwheels
     font.origin = True
     for angle in range(0, 360, 45):
         font.render_to(screen, (200, 500), ")", pygame.Color('black'),
-                       ptsize=48, rotation=angle)
+                       size=48, rotation=angle)
     font.vertical = True
     for angle in range(15, 375, 30):
         font.render_to(screen, (600, 400), "|^*", pygame.Color('orange'),
-                       ptsize=48, rotation=angle)
+                       size=48, rotation=angle)
     font.vertical = False
     font.origin = False
 
     utext = pygame.compat.as_unicode(r"I \u2665 Unicode")
     font.render_to(screen, (298, 320), utext, pygame.Color(0, 0xCC, 0xDD),
-                   None, ptsize=64)
+                   None, size=64)
 
     utext = pygame.compat.as_unicode(r"\u2665")
     font.render_to(screen, (480, 32), utext, colors["grey_light"],
-                   colors["red"], ptsize=148)
+                   colors["red"], size=148)
 
     font.render_to(screen, (380, 380), "...yes, this is an SDL surface",
                    pygame.Color(0, 0, 0),
-                   None, ptsize=24, style=freetype.STYLE_STRONG)
+                   None, size=24, style=freetype.STYLE_STRONG)
 
     pygame.display.flip()
 
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.