Internal change to entergame, fix image-offset-y mistake, change the way default font is set in skins.
This commit is contained in:
parent
e78edad4c6
commit
0f980ec18b
|
@ -53,33 +53,34 @@ MainWindow
|
||||||
!text: tr('Protocol')
|
!text: tr('Protocol')
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.top: serverHostTextEdit.bottom
|
anchors.top: serverHostTextEdit.bottom
|
||||||
anchors.right: portLabel.left
|
text-auto-resize: true
|
||||||
margin-right: 10
|
margin-right: 10
|
||||||
margin-top: 8
|
margin-top: 8
|
||||||
|
|
||||||
ComboBox
|
ComboBox
|
||||||
id: protocolComboBox
|
id: protocolComboBox
|
||||||
anchors.left: protocolLabel.left
|
anchors.left: protocolLabel.left
|
||||||
anchors.right: protocolLabel.right
|
anchors.right: parent.horizontalCenter
|
||||||
anchors.top: protocolLabel.bottom
|
anchors.top: protocolLabel.bottom
|
||||||
margin-top: 2
|
margin-top: 2
|
||||||
|
margin-right: 3
|
||||||
width: 90
|
width: 90
|
||||||
|
|
||||||
MenuLabel
|
MenuLabel
|
||||||
id: portLabel
|
id: portLabel
|
||||||
!text: tr('Port')
|
!text: tr('Port')
|
||||||
anchors.right: parent.right
|
anchors.left: serverPortTextEdit.left
|
||||||
anchors.top: serverHostTextEdit.bottom
|
anchors.top: serverHostTextEdit.bottom
|
||||||
margin-top: 8
|
margin-top: 8
|
||||||
width: 70
|
text-auto-resize: true
|
||||||
|
|
||||||
TextEdit
|
TextEdit
|
||||||
id: serverPortTextEdit
|
id: serverPortTextEdit
|
||||||
text: 7171
|
text: 7171
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.left: portLabel.left
|
anchors.left: parent.horizontalCenter
|
||||||
anchors.top: portLabel.bottom
|
anchors.top: protocolComboBox.top
|
||||||
margin-top: 2
|
margin-left: 3
|
||||||
|
|
||||||
CheckBox
|
CheckBox
|
||||||
id: rememberPasswordBox
|
id: rememberPasswordBox
|
||||||
|
|
|
@ -117,11 +117,11 @@ function Skins.loadSkin(skin)
|
||||||
if skin.fonts then
|
if skin.fonts then
|
||||||
for i=1,#skin.fonts do
|
for i=1,#skin.fonts do
|
||||||
g_fonts.importFont('skins/' .. lowerName .. '/fonts/' .. skin.fonts[i])
|
g_fonts.importFont('skins/' .. lowerName .. '/fonts/' .. skin.fonts[i])
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
if i == 1 then
|
if skin.defaultFont then
|
||||||
g_fonts.setDefaultFont(skin.fonts[i])
|
g_fonts.setDefaultFont(skin.defaultFont)
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
if skin.styles then
|
if skin.styles then
|
||||||
|
|
|
@ -8,6 +8,7 @@ local skin = {
|
||||||
'verdana-11px-rounded',
|
'verdana-11px-rounded',
|
||||||
'terminus-14px-bold'
|
'terminus-14px-bold'
|
||||||
},
|
},
|
||||||
|
defaultFont = 'verdana-11px-antialised',
|
||||||
|
|
||||||
styles = {
|
styles = {
|
||||||
'buttons.otui',
|
'buttons.otui',
|
||||||
|
|
|
@ -413,7 +413,7 @@ public:
|
||||||
void setImageSource(const std::string& source);
|
void setImageSource(const std::string& source);
|
||||||
void setImageClip(const Rect& clipRect) { m_imageClipRect = clipRect; updateImageCache(); }
|
void setImageClip(const Rect& clipRect) { m_imageClipRect = clipRect; updateImageCache(); }
|
||||||
void setImageOffsetX(int x) { m_imageRect.setX(x); updateImageCache(); }
|
void setImageOffsetX(int x) { m_imageRect.setX(x); updateImageCache(); }
|
||||||
void setImageOffsetY(int y) { m_imageRect.setX(y); updateImageCache(); }
|
void setImageOffsetY(int y) { m_imageRect.setY(y); updateImageCache(); }
|
||||||
void setImageOffset(const Point& pos) { m_imageRect.move(pos); updateImageCache(); }
|
void setImageOffset(const Point& pos) { m_imageRect.move(pos); updateImageCache(); }
|
||||||
void setImageWidth(int width) { m_imageRect.setWidth(width); updateImageCache(); }
|
void setImageWidth(int width) { m_imageRect.setWidth(width); updateImageCache(); }
|
||||||
void setImageHeight(int height) { m_imageRect.setHeight(height); updateImageCache(); }
|
void setImageHeight(int height) { m_imageRect.setHeight(height); updateImageCache(); }
|
||||||
|
|
Loading…
Reference in New Issue