1
0
mirror of https://github.com/Swordfish90/cool-retro-term.git synced 2025-01-31 02:01:19 +00:00

Refactored frames

This commit is contained in:
Filippo Scognamiglio 2013-12-25 18:44:46 +01:00
parent c80c73f591
commit 750d03979c
12 changed files with 70 additions and 37 deletions

View File

@ -21,9 +21,28 @@ OTHER_FILES += \
$$PWD/qml/cool-old-term/HighlightArea.qml \ $$PWD/qml/cool-old-term/HighlightArea.qml \
$$PWD/qml/cool-old-term/ShaderSettings.qml \ $$PWD/qml/cool-old-term/ShaderSettings.qml \
$$PWD/qml/images/frame.png \ $$PWD/qml/images/frame.png \
qml/cool-old-term/SettingsWindow.qml \ $$PWD/qml/cool-old-term/SettingsWindow.qml \
qml/cool-old-term/SettingComponent.qml \ $$PWD/qml/cool-old-term/SettingComponent.qml \
qml/cool-old-term/ColorButton.qml \ $$PWD/qml/cool-old-term/ColorButton.qml \
qml/cool-old-term/TerminalFrame.qml \ $$PWD/qml/cool-old-term/TerminalFrame.qml \
qml/cool-old-term/WhiteFrameShader.qml \ $$PWD/qml/cool-old-term/WhiteFrameShader.qml \
qml/cool-old-term/NoFrameShader.qml $$PWD/qml/cool-old-term/NoFrameShader.qml \
$$PWD/qml/cool-old-term/WhiteSimpleFrame.qml \
qml/cool-old-term/BlackRoughFrame.qml \
qml/cool-old-term/Frames/BlackRoughFrame.qml \
qml/cool-old-term/Frames/NoFrameShader.qml \
qml/cool-old-term/Frames/WhiteFrameShader.qml \
qml/cool-old-term/Frames/WhiteSimpleFrame.qml \
qml/cool-old-term/Frames/TerminalFrame.qml \
qml/cool-old-term/Frames/utils/NoFrameShader.qml \
qml/cool-old-term/Frames/utils/TerminalFrame.qml \
qml/cool-old-term/Frames/utils/WhiteFrameShader.qml \
qml/cool-old-term/frames/WhiteSimpleFrame.qml \
qml/cool-old-term/frames/BlackRoughFrame.qml \
qml/cool-old-term/frames/utils/NoFrameShader.qml \
qml/cool-old-term/frames/utils/TerminalFrame.qml \
qml/cool-old-term/frames/utils/WhiteFrameShader.qml \
qml/cool-old-term/frames/images/screen-frame.png \
qml/cool-old-term/frames/images/screen-frame-normals.png \
qml/cool-old-term/frames/images/black-frame.png \
qml/cool-old-term/frames/images/black-frame-normals.png

View File

@ -1,4 +1,4 @@
import QtQuick 2.0 import QtQuick 2.1
Item{ Item{
property real ambient_light: 0.2 property real ambient_light: 0.2

View File

@ -0,0 +1,19 @@
import QtQuick 2.1
import "utils"
TerminalFrame{
id: frame
z: 2.1
anchors.fill: parent
addedWidth: 200
addedHeight: 370
borderLeft: 148
borderRight: 148
borderTop: 232
borderBottom: 232
imageSource: "../images/black-frame.png"
normalsSource: "../images/black-frame-normals.png"
sourceRect: Qt.rect(-80, -90, terminal.width + 160, terminal.height + 180 )
shaderString: "WhiteFrameShader.qml"
}

View File

@ -0,0 +1,19 @@
import QtQuick 2.0
import "utils"
TerminalFrame{
id: frame
z: 2.1
anchors.fill: parent
addedWidth: 140
addedHeight: 140
borderLeft: 116
borderRight: 116
borderTop: 116
borderBottom: 116
imageSource: "../images/screen-frame.png"
normalsSource: "../images/screen-frame-normals.png"
sourceRect: Qt.rect(-65, -75, terminal.width + 130, terminal.height + 150)
shaderString: "WhiteFrameShader.qml"
}

View File

Before

Width:  |  Height:  |  Size: 1.4 MiB

After

Width:  |  Height:  |  Size: 1.4 MiB

View File

Before

Width:  |  Height:  |  Size: 1.1 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

View File

Before

Width:  |  Height:  |  Size: 646 KiB

After

Width:  |  Height:  |  Size: 646 KiB

View File

Before

Width:  |  Height:  |  Size: 571 KiB

After

Width:  |  Height:  |  Size: 571 KiB

View File

@ -190,38 +190,14 @@ ApplicationWindow{
}" }"
} }
// TerminalFrame{ Loader{
// id: frame property rect sourceRect
// z: 2.1
// anchors.fill: parent
// addedWidth: 140
// addedHeight: 140
// borderLeft: 116
// borderRight: 116
// borderTop: 116
// borderBottom: 116
// imageSource: "../images/screen-frame.png"
// normalsSource: "../images/screen-frame-normals.png"
// sourceRect: Qt.rect(-65, -75, terminal.width + 130, terminal.height + 150)
// shaderString: "WhiteFrameShader.qml"
// }
TerminalFrame{
id: frame id: frame
z: 2.1
anchors.fill: parent anchors.fill: parent
addedWidth: 200 z: 2.1
addedHeight: 370 source: "./frames/WhiteSimpleFrame.qml"
borderLeft: 148 onLoaded: sourceRect = item.sourceRect;
borderRight: 148
borderTop: 232
borderBottom: 232
imageSource: "../images/black-frame.png"
normalsSource: "../images/black-frame-normals.png"
sourceRect: Qt.rect(-80, -90, terminal.width + 160, terminal.height + 180 )
shaderString: "WhiteFrameShader.qml"
} }
TerminalScreen { TerminalScreen {