Merge branch 'development' of https://github.com/TorqueGameEngines/Torque3D into NilsUI_Updates_GuiClassTweaks

This commit is contained in:
Areloch 2023-09-05 17:49:27 -05:00
commit 24c758d383
58 changed files with 98 additions and 62 deletions

View file

@ -307,6 +307,9 @@ bool alwaysUseDebugOutput = true;
bool useTimestamp = false;
bool useRealTimestamp = false;
static U32 initTime = Platform::getRealMilliseconds();
U32 startTime = initTime;
ConsoleFunctionGroupBegin( Clipboard, "Miscellaneous functions to control the clipboard and clear the console.");
DefineEngineFunction( cls, void, (), , "()"
@ -327,7 +330,7 @@ DefineEngineFunction( getClipboard, const char*, (), , "()"
};
DefineEngineFunction( setClipboard, bool, (const char* text), , "(string text)"
"@brief Set the system clipboard.\n\n"
"@brief Set the system clipboard.\n\n"
"@internal")
{
return Platform::setClipboard(text);
@ -335,6 +338,20 @@ DefineEngineFunction( setClipboard, bool, (const char* text), , "(string text)"
ConsoleFunctionGroupEnd( Clipboard );
DefineEngineFunction( resetTimeStamp, void, (), , "()"
"@brief Reset the timestamp to 0 ms.\n\n"
"@ingroup Console")
{
startTime = Platform::getRealMilliseconds();
};
DefineEngineFunction( getInitTime, int, (), , "()"
"@brief Get the initialization time in miliseconds.\n\n"
"@internal")
{
return initTime;
};
void postConsoleInput( RawData data );
@ -644,7 +661,7 @@ static void _printf(ConsoleLogEntry::Level level, ConsoleLogEntry::Type type, co
{
if (!active)
return;
Con::active = false;
Con::active = false;
char buffer[8192] = {};
U32 offset = 0;
@ -664,16 +681,15 @@ static void _printf(ConsoleLogEntry::Level level, ConsoleLogEntry::Type type, co
if (useTimestamp)
{
static U32 startTime = Platform::getRealMilliseconds();
U32 curTime = Platform::getRealMilliseconds() - startTime;
offset += dSprintf(buffer + offset, sizeof(buffer) - offset, "[+%4d.%03d]", U32(curTime * 0.001), curTime % 1000);
}
if (useTimestamp || useRealTimestamp) {
if (useTimestamp || useRealTimestamp)
{
offset += dSprintf(buffer + offset, sizeof(buffer) - offset, " ");
}
dVsprintf(buffer + offset, sizeof(buffer) - offset, fmt, argptr);
for(S32 i = 0; i < gConsumers.size(); i++)
@ -2652,3 +2668,5 @@ void ConsoleStackFrameSaver::restore()
gCallStack.popFrame();
}
}
//------------------------------------------------------------------------------

View file

@ -38,6 +38,8 @@ const ColorI ColorI::BLACK( 0, 0, 0 );
const ColorI ColorI::RED( 255, 0, 0 );
const ColorI ColorI::GREEN( 0, 255, 0 );
const ColorI ColorI::BLUE( 0, 0, 255 );
const ColorI ColorI::DARK(24, 24, 24);
const ColorI ColorI::LIGHT(120, 120, 120);
#include "console/console.h"
#include "console/consoleTypes.h"

View file

@ -196,6 +196,8 @@ public:
static const ColorI RED;
static const ColorI GREEN;
static const ColorI BLUE;
static const ColorI LIGHT;
static const ColorI DARK;
};
//-----------------------------------------------------------------------------

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 276 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 131 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 908 B

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 250 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

View file

@ -165,6 +165,7 @@ new GuiControlProfile(GuiMenuScrollProfile)
bitmapAsset = "Core_GUI:scrollBar_image";
hasBitmapArray = true;
category = "Core";
fontSize = 15;
};
if(!isObject(GuiOverlayProfile))

Binary file not shown.

Before

Width:  |  Height:  |  Size: 131 B

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

@ -20,7 +20,7 @@ $guiContent = new GuiChunkedBitmapCtrl(LoadingGui) {
new GuiControl() {
position = "263 301";
extent = "497 166";
extent = "360 360";
minExtent = "8 8";
horizSizing = "center";
vertSizing = "center";
@ -36,11 +36,11 @@ $guiContent = new GuiChunkedBitmapCtrl(LoadingGui) {
canSaveDynamicFields = "0";
new GuiBitmapCtrl() {
bitmapAsset = "UI:panel_image";
bitmapAsset = "UI:backgrounddark_image";
color = "255 255 255 255";
wrap = "0";
position = "0 0";
extent = "497 166";
extent = "360 360";
minExtent = "8 2";
horizSizing = "right";
vertSizing = "bottom";
@ -57,11 +57,11 @@ $guiContent = new GuiChunkedBitmapCtrl(LoadingGui) {
bitmapAsset = "UI:Torque_3D_logo_alt_image";
color = "255 255 255 255";
wrap = "0";
position = "27 6";
extent = "443 139";
position = "0 0";
extent = "360 360";
minExtent = "8 2";
horizSizing = "center";
vertSizing = "bottom";
vertSizing = "center";
profile = "GuiDefaultProfile";
visible = "1";
active = "1";
@ -79,11 +79,11 @@ $guiContent = new GuiChunkedBitmapCtrl(LoadingGui) {
anchorBottom = "0";
anchorLeft = "1";
anchorRight = "0";
position = "17 126";
extent = "464 24";
position = "30 320";
extent = "300 24";
minExtent = "8 2";
horizSizing = "center";
vertSizing = "bottom";
horizSizing = "width";
vertSizing = "top";
profile = "GuiProgressBitmapProfile";
visible = "1";
active = "1";
@ -102,11 +102,11 @@ $guiContent = new GuiChunkedBitmapCtrl(LoadingGui) {
anchorBottom = "0";
anchorLeft = "1";
anchorRight = "0";
position = "28 144";
extent = "440 20";
position = "0 340";
extent = "360 20";
minExtent = "8 8";
horizSizing = "center";
vertSizing = "bottom";
vertSizing = "top";
profile = "GuiMenuTextProfile";
visible = "1";
active = "1";

View file

@ -10,11 +10,30 @@ $guiContent = new GuiChunkedBitmapCtrl(MainMenuGui) {
isContainer = "1";
superClass = "UINavigation";
canSaveDynamicFields = "0";
new GuiBitmapCtrl(SideBackgroundImage) {
bitmapAsset = "UI:menu_side_background_image";
color = "255 255 255 255";
wrap = "0";
position = "0 0";
extent = "900 600";
minExtent = "8 2";
horizSizing = "right";
vertSizing = "top";
profile = "GuiDefaultProfile";
visible = "1";
active = "1";
tooltipProfile = "GuiToolTipProfile";
hovertime = "1000";
isContainer = "0";
canSave = "1";
canSaveDynamicFields = "0";
};
new GuiBitmapCtrl(MainMenuAppLogo) {
BitmapAsset = "UI:Torque_3D_logo_alt_image";
BitmapAsset = "UI:Torque_3D_logo_image";
position = "550 30";
extent = "443 139";
extent = "360 100";
horizSizing = "left";
profile = "GuiDefaultProfile";
tooltipProfile = "GuiToolTipProfile";

View file

@ -34,8 +34,8 @@ function loadStartup()
// be in consecutive numerical order
StartupGui.bitmap[0] = "UI:backgrounddark_image";
StartupGui.logo[0] = "UI:Torque_3D_logo_alt_image";
StartupGui.logoPos[0] = "178 251";
StartupGui.logoExtent[0] = "443 139";
StartupGui.logoPos[0] = "220 120";
StartupGui.logoExtent[0] = "360 360";
// Call the next() function to set our firt
// splash screen

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.9 KiB

After

Width:  |  Height:  |  Size: 9.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 659 B

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 2.8 KiB

View file

Before

Width:  |  Height:  |  Size: 593 B

After

Width:  |  Height:  |  Size: 593 B

View file

@ -1,8 +1,3 @@
<ImageAsset
canSave="true"
canSaveDynamicFields="true"
AssetName="clear_btn_d_image"
imageFile="@assetFile=clear-btn_d.png"
UseMips="true"
isHDRImage="false"
imageType="Albedo" />
AssetName="clearbtn_d_image"
imageFile="@assetFile=clear_btn_d.png"/>

View file

Before

Width:  |  Height:  |  Size: 595 B

After

Width:  |  Height:  |  Size: 595 B

View file

@ -1,8 +1,3 @@
<ImageAsset
canSave="true"
canSaveDynamicFields="true"
AssetName="clear_btn_h_image"
imageFile="@assetFile=clear-btn_h.png"
UseMips="true"
isHDRImage="false"
imageType="Albedo" />
AssetName="clearbtn_h_image"
imageFile="@assetFile=clear_btn_h.png"/>

View file

Before

Width:  |  Height:  |  Size: 377 B

After

Width:  |  Height:  |  Size: 377 B

View file

@ -1,8 +1,3 @@
<ImageAsset
canSave="true"
canSaveDynamicFields="true"
AssetName="clear_btn_n_image"
imageFile="@assetFile=clear-btn_n.png"
UseMips="true"
isHDRImage="false"
imageType="Albedo" />
AssetName="clearbtn_n_image"
imageFile="@assetFile=clear_btn_n.png"/>

View file

@ -1,3 +0,0 @@
<ImageAsset
AssetName="clearbtn_d_image"
imageFile="@assetFile=clearbtn_d.png"/>

View file

@ -1,3 +0,0 @@
<ImageAsset
AssetName="clearbtn_h_image"
imageFile="@assetFile=clearbtn_h.png"/>

View file

@ -1,3 +0,0 @@
<ImageAsset
AssetName="clearbtn_n_image"
imageFile="@assetFile=clearbtn_n.png"/>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 276 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 908 B

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 250 KiB

View file

@ -0,0 +1,8 @@
<ImageAsset
canSave="true"
canSaveDynamicFields="true"
AssetName="menu_image"
imageFile="@assetFile=menu.png"
UseMips="true"
isHDRImage="false"
imageType="Albedo" />

View file

@ -0,0 +1,8 @@
<ImageAsset
canSave="true"
canSaveDynamicFields="true"
AssetName="menu_side_background_image"
imageFile="@assetFile=menu_side_background.png"
UseMips="true"
isHDRImage="false"
imageType="Albedo" />

Binary file not shown.

Before

Width:  |  Height:  |  Size: 279 B

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 549 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 484 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 993 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 290 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 561 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 494 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 843 B

After

Width:  |  Height:  |  Size: 3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 118 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 982 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 939 B

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 250 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 226 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

View file

@ -95,11 +95,11 @@ new GuiControlProfile( GuiMenuButtonProfile )
fontColorNA = $TextDisabledColor;
fontColorSEL = $TextMediumEmphasisColor;
fillColor = "40 40 40";
fillColorHL = "56 56 56";
fillColorHL = "49 34 37";
fillColorNA = "40 40 40";
borderColor = "87 87 87";
borderColorNA = "0 0 0";
borderColorHL = "255 255 255";
borderColorHL = "194 64 64";
fixedExtent = false;
justify = "center";
canKeyFocus = false;
@ -366,16 +366,17 @@ new GuiControlProfile( GuiPopUpMenuDefault : GuiDefaultProfile )
border = 0;
borderThickness = 0;
fixedExtent = true;
bitmapAsset = "UI:scrollBar_image";
hasBitmapArray = true;
fillColor = EditorSettings.value("Theme/fieldBGColor");//"255 255 255";//100
fillColorHL = EditorSettings.value("Theme/fieldBGHLColor");//"91 101 116";
fillColorSEL = EditorSettings.value("Theme/fieldBGSELColor");//"91 101 116";
fontColor = EditorSettings.value("Theme/fieldTextColor");//"215 215 215";
fontColorHL = EditorSettings.value("Theme/fieldTextHLColor");//"215 215 215";
fontColorSEL = EditorSettings.value("Theme/fieldTextSELColor");//"215 215 215";
fontColorNA = EditorSettings.value("Theme/fieldTextColor");//"215 215 215";
borderColor = EditorSettings.value("Theme/dividerDarkColor");
profileForChildren = GuiPopupMenuItemBorder;
fillColor = "242 241 240 ";//"255 255 255";//100
fillColorHL = "228 228 235 ";//"204 203 202";
fillColorSEL = "98 100 137 ";//"204 203 202";
// font color is black
fontColorHL = "0 0 0 ";//"0 0 0";
fontColorSEL = "255 255 255";//"0 0 0";
borderColor = "100 100 100";
category = "Core";
};
@ -552,4 +553,5 @@ singleton GuiControlProfile(SliderBitmapGUIProfile)
bitmapAsset = "UI:optionsMenuSliderBitmapArray_image";
hasBitmapArray = true;
opaque = false;
borderColor = "0 0 0 255";
};