94 lines
2.2 KiB
Plaintext
94 lines
2.2 KiB
Plaintext
Panel
|
|
Label
|
|
!text: tr('Graphics Engine:')
|
|
anchors.left: parent.left
|
|
anchors.top: parent.top
|
|
|
|
ButtonBox
|
|
anchors.left: prev.right
|
|
anchors.verticalCenter: prev.verticalCenter
|
|
id: opengl1
|
|
text: OpenGL 1
|
|
size: 80 20
|
|
margin-left: 6
|
|
|
|
ButtonBox
|
|
anchors.left: prev.right
|
|
anchors.verticalCenter: prev.verticalCenter
|
|
id: opengl2
|
|
text: OpenGL 2
|
|
size: 80 20
|
|
margin-left: 4
|
|
|
|
OptionCheckBox
|
|
id: vsync
|
|
!text: tr('Enable vertical synchronization')
|
|
!tooltip: tr('Limits FPS to 60')
|
|
|
|
OptionCheckBox
|
|
id: showfps
|
|
!text: tr('Show frame rate')
|
|
|
|
OptionCheckBox
|
|
id: fullscreen
|
|
!text: tr('Fullscreen')
|
|
|
|
Label
|
|
id: backgroundFrameRateLimitLabel
|
|
!text: tr('Background pane framerate limit: %s', 'max')
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
anchors.top: prev.bottom
|
|
margin-top: 6
|
|
|
|
HorizontalScrollBar
|
|
id: backgroundFrameRateScrollBar
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
anchors.top: prev.bottom
|
|
margin-top: 3
|
|
minimum: 10
|
|
maximum: 201
|
|
value: 201
|
|
step: 1
|
|
@onValueChange: |
|
|
local value = self:getValue()
|
|
local text = value
|
|
if value == self:getMaximum() then
|
|
text = 'max'
|
|
value = 0
|
|
end
|
|
|
|
self:getParent():getChildById('backgroundFrameRateLimitLabel'):setText(tr('Background pane framerate limit: %s', text))
|
|
g_app.setBackgroundPaneMaxFps(value)
|
|
|
|
Label
|
|
id: foregroundFrameRateLimitLabel
|
|
!text: tr('Foreground pane framerate limit: %s', '8')
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
anchors.top: prev.bottom
|
|
margin-top: 6
|
|
|
|
HorizontalScrollBar
|
|
id: foregroundFrameRateScrollBar
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
anchors.top: prev.bottom
|
|
margin-top: 3
|
|
minimum: 1
|
|
maximum: 61
|
|
value: 8
|
|
step: 1
|
|
@onValueChange: |
|
|
local value = self:getValue()
|
|
local text = value
|
|
if value == self:getMaximum() then
|
|
text = 'max'
|
|
value = 0
|
|
end
|
|
|
|
self:getParent():getChildById('foregroundFrameRateLimitLabel'):setText(tr('Foreground pane framerate limit: %s', text))
|
|
g_app.setForegroundPaneMaxFps(value)
|
|
|