MCPcopy Create free account
hub / github.com/SFML/SFML / textEventDescription

Function textEventDescription

examples/keyboard/Keyboard.cpp:730–741  ·  view source on GitHub ↗

Make a string describing a text event

Source from the content-addressed store, hash-verified

728
729// Make a string describing a text event
730sf::String textEventDescription(const sf::Event::TextEntered& textEntered)
731{
732 sf::String text = "Text Entered\n\n";
733 text += textEntered.unicode;
734 text += "\nU+";
735
736 std::ostringstream oss;
737 oss << std::hex << std::setw(4) << std::setfill('0') << std::uint32_t{textEntered.unicode};
738 text += oss.str();
739
740 return text;
741}
742
743} // namespace
744

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected