MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / setText

Method setText

Engine/source/gui/controls/guiTextCtrl.cpp:186–202  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

184}
185
186void GuiTextCtrl::setText(const char *txt)
187{
188 //make sure we don't call this before onAdd();
189 if( !mProfile )
190 return;
191
192 // The txt pointer is sometimes the same as the mText pointer, so make sure
193 // we don't call strncpy with overlapping src and dest.
194 if (txt && txt != mText)
195 dStrncpy(mText, (UTF8*)txt, MAX_STRING_LENGTH);
196 mText[MAX_STRING_LENGTH] = '\0';
197
198 setVariable((char*)mText);
199 setUpdate();
200
201 autoResize();
202}
203
204void GuiTextCtrl::setTextID(const char *id)
205{

Callers 15

loadConfigMethod · 0.45
saveCurrentConfigMethod · 0.45
enableApplyButtonMethod · 0.45
updateResamplerLabelMethod · 0.45
selectDecoderFileMethod · 0.45
updateHrtfModeLabelMethod · 0.45
selectOSSPlaybackMethod · 0.45
selectOSSCaptureMethod · 0.45
selectSolarisPlaybackMethod · 0.45
selectWaveOutputMethod · 0.45
MainWindowMethod · 0.45
onConnectMethod · 0.45

Calls 2

dStrncpyFunction · 0.85
setVariableFunction · 0.85

Tested by 6

MainWindowMethod · 0.36
onConnectMethod · 0.36
onDisconnectMethod · 0.36
onClearMethod · 0.36
setValueMethod · 0.36
onAddMethod · 0.36