MCPcopy Create free account
hub / github.com/MyGUI/mygui / parseColour2

Method parseColour2

Tools/EditorFramework/PropertyColourControl.cpp:170–195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

168 }
169
170 bool PropertyColourControl::parseColour2(const std::string& _value, MyGUI::Colour& _resultValue)
171 {
172 if (!_value.empty())
173 {
174 float red;
175 float green;
176 float blue;
177 std::istringstream stream(_value);
178 stream >> red >> green >> blue;
179 if (!stream.fail())
180 {
181 int item = stream.get();
182 while (item != -1)
183 {
184 if (item != ' ' && item != '\t')
185 return false;
186 item = stream.get();
187 }
188
189 _resultValue = MyGUI::Colour(red, green, blue);
190 return true;
191 }
192 }
193
194 return false;
195 }
196
197 bool PropertyColourControl::parseColour3(const std::string& _value, MyGUI::Colour& _resultValue)
198 {

Callers

nothing calls this directly

Calls 3

ColourFunction · 0.50
emptyMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected