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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - codinglexernewbie

Pages: [1]
Graphics / is there a way in the library to make this more efficient?
« on: December 24, 2022, 08:58:12 pm »
   I'm planning on adding a text-highlighting feature to my little project, (I wrote one before, but it was spaghetti code and very buggy)
I started with   
case sf::Event::MouseButtonReleased:
    if(sf::Mouse::getPosition(MaWind).y != Mcoords[1]||sf::Mouse::getPosition(MaWind).x != Mcoords[0])
//Mcoords[0] is the x pos stored from the mouse button being clicked and you get it for Mcoords[1]
but then I realized having to check an if-statement every time the mouse button seems rather inefficient, is there a way i should be doing it other than this or this is the best possible?

Window / How to get unicode to be typed through sf::TextEntered
« on: September 24, 2022, 07:46:49 am »
I want to be able to get Unicode letters e.g: ∏ by typing alt + 8719 like possible in Wordpad, but it doesn't seem to work using the default instead it turns into ☼(15), why does it reset after 256?, and is there a way to do what I want in the standard lib?

Graphics / is it possible to set individual glyphs size in sfml?
« on: July 11, 2022, 11:35:22 am »
for example i have a glyph:'Σ' and i want to make it 30 by 50, how do i do that?
so in a string : aΣ3 where the character height is 40, i want the Σ to be 30

Graphics / check which glyph is at a position
« on: July 07, 2022, 09:37:21 am »
say my mouse clicks on '√' in the SF::text "a√a" i want to know which glyph is at the position the mouse clicked and the glyph's bounding box's location,how would i do that?

Pages: [1]