mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
New build-in variables: #WORKAREAWIDTH#, #WORKAREAHEIGHT#, #SCREENAREAWIDTH#, #SCREENAREAHEIGHT#
Added support for math formulas for the X, Y, W, H, WindowX and WindowY (e.g. "WindowX=(#WORKAREAWIDTH# / 2)"). The formula must be surrounded by parenthesis.
This commit is contained in:
@ -221,6 +221,10 @@ void CMeter::ReadConfig(const WCHAR* section)
|
||||
{
|
||||
m_RelativeX = POSITION_RELATIVE_BR;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_X = (int)parser.ReadFormula(section, L"X", 0.0);
|
||||
}
|
||||
}
|
||||
|
||||
const std::wstring& y = parser.ReadString(section, L"Y", L"0");
|
||||
@ -235,10 +239,14 @@ void CMeter::ReadConfig(const WCHAR* section)
|
||||
{
|
||||
m_RelativeY = POSITION_RELATIVE_BR;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_Y = (int)parser.ReadFormula(section, L"Y", 0.0);
|
||||
}
|
||||
}
|
||||
|
||||
m_W = parser.ReadInt(section, L"W", 1);
|
||||
m_H = parser.ReadInt(section, L"H", 1);
|
||||
m_W = (int)parser.ReadFormula(section, L"W", 1.0);
|
||||
m_H = (int)parser.ReadFormula(section, L"H", 1.0);
|
||||
|
||||
m_Hidden = 0!=parser.ReadInt(section, L"Hidden", 0);
|
||||
m_SolidBevel = (BEVELTYPE)parser.ReadInt(section, L"BevelType", m_SolidBevel);
|
||||
|
Reference in New Issue
Block a user