Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Width of a sf::String?  (Read 14230 times)

0 Members and 1 Guest are viewing this topic.

NeWsOfTzzz

  • Newbie
  • *
  • Posts: 15
    • View Profile
Width of a sf::String?
« on: August 20, 2008, 02:21:09 pm »
Is there any way to find out the width of a text? For example to cut it if it gets too long or to display a cursor?

Daazku

  • Hero Member
  • *****
  • Posts: 896
    • View Profile
Width of a sf::String?
« Reply #1 on: August 20, 2008, 02:28:55 pm »
Check the string documentation and the tutorial..
Pensez à mettre le tag [Résolu] une fois la réponse à votre question trouvée.
Remember to add the tag [Solved] when you got an answer to your question.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Width of a sf::String?
« Reply #2 on: August 20, 2008, 02:32:04 pm »
For cursor stuff, check the 1.4 (SVN) documentation and tutorial.
Laurent Gomila - SFML developer

NeWsOfTzzz

  • Newbie
  • *
  • Posts: 15
    • View Profile
Width of a sf::String?
« Reply #3 on: August 20, 2008, 02:32:08 pm »
Just as you say it I found it! I posted too fast :/
It was not in the tutorial though! ;)

I didn't see the "GetRect()" function even though i looked 2 times over all functions of the string class -.-

Can be closed, sorry :p

ATM I'm using 1.3 though..

 

anything