import QtQuick 2.4
import QtQuick.Controls 1.2
Rectangle {
id: mainContainer
width: 360
height: 640
property alias mainContainer: mainContainer
property alias taxaJurosSpinBox: taxaJurosSpinBox
property alias periodoJurosComboBox: periodoJurosComboBox
property alias calcularButton: calcularButton
property alias conversaoDiariaValorText: conversaoDiariaValorText
property alias conversaoMensalValorText: conversaoMensalValorText
property alias conversaoBimestralValorText: conversaoBimestralValorText
property alias conversaoTrimestralValorText: conversaoTrimestralValorText
property alias conversaoSemestralValorText: conversaoSemestralValorText
property alias conversaoAnualValorText: conversaoAnualValorText
color: "#ffffff"
Rectangle {
id: tituloRectangle
anchors.horizontalCenter: parent.horizontalCenter
y: parent.y
width: parent.width
height: parent.height * 0.10
gradient: Gradient {
GradientStop {
position: 0
color: "#fe3001"
}
GradientStop {
position: 1
color: "#fe8548"
}
}
Image {
antialiasing: false
source: "Imagens/InterestC-Mobile-Text.png"
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
}
}
Label {
id: taxaJurosLabel
anchors.horizontalCenter: parent.horizontalCenter
y: parent.y + tituloRectangle.height * 1.3
text: qsTr("Taxa de juros") + " (%)"
font.pointSize: 18
}
Rectangle {
id: taxaJurosInputRectangle
width: parent.width * 0.85
height: parent.height * 0.10
anchors.horizontalCenter: parent.horizontalCenter
y: parent.y + tituloRectangle.height * 1.7
SpinBox {
id: taxaJurosSpinBox
anchors.verticalCenter: parent.verticalCenter
anchors.left: parent.left
width: parent.width * 0.47
height: parent.height * 0.6
font.pointSize: 16
horizontalAlignment: Text.AlignHCenter
decimals: 2
minimumValue: 0
maximumValue: 100
}
ComboBox {
id: periodoJurosComboBox
width: parent.width * 0.47
height: parent.height * 0.6
anchors.verticalCenter: parent.verticalCenter
anchors.right: parent.right
model: [qsTr("Diária"), qsTr("Mensal"), qsTr("Bimestral"), qsTr("Trimestral"), qsTr("Semestral"), qsTr("Anual")]
}
}
Button {
id: calcularButton
anchors.horizontalCenter: parent.horizontalCenter
y: 1.03 * (taxaJurosInputRectangle.y + taxaJurosInputRectangle.height)
width: parent.width * 0.85
height: taxaJurosInputRectangle.height * 0.6
text: qsTr("Calcular")
}
Rectangle {
id: conversoesRectangle
width: parent.width * 0.9
height: parent.height * 0.61
anchors.horizontalCenter: parent.horizontalCenter
y: 1.05 * (calcularButton.y + calcularButton.height)
//property variant espacamentoConversoes: 1.03
Text {
id: conversaoTituloText
anchors.horizontalCenter: parent.horizontalCenter
anchors.top: parent.top
text: qsTr("Conversões (%) ")
font.bold: true
font.pixelSize: 25
}
Text {
id: conversaoDiariaText
anchors.left: parent.left
y: parent.height / 7
text: qsTr("Ao dia: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoDiariaValorText
anchors.right: parent.right
y: conversaoDiariaText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
Text {
id: conversaoMensalText
anchors.left: parent.left
y: parent.height / 7 * 2
text: qsTr("Ao mês: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoMensalValorText
anchors.right: parent.right
y: conversaoMensalText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
Text {
id: conversaoBimestralText
anchors.left: parent.left
y: parent.height / 7 * 3
text: qsTr("Ao bimestre: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoBimestralValorText
anchors.right: parent.right
y: conversaoBimestralText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
Text {
id: conversaoTrimestralText
anchors.left: parent.left
y: parent.height / 7 * 4
text: qsTr("Ao trimestre: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoTrimestralValorText
anchors.right: parent.right
y: conversaoTrimestralText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
Text {
id: conversaoSemestralText
anchors.left: parent.left
y: parent.height / 7 * 5
text: qsTr("Ao semestre: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoSemestralValorText
anchors.right: parent.right
y: conversaoSemestralText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
Text {
id: conversaoAnualText
anchors.left: parent.left
y: parent.height / 7 * 6
text: qsTr("Ao ano: ")
font.bold: true
font.pixelSize: 20
}
Text {
id: conversaoAnualValorText
anchors.right: parent.right
y: conversaoAnualText.y
font.bold: true
font.pixelSize: 20
width: parent.width * 0.2
height: parent.height * 0.1
horizontalAlignment: Text.AlignRight
}
}
}
Bookmarks