Browse Source

Merge pull request 'fixing_layout' (#5) from fixing_layout into master

Reviewed-on: http://code.petrovs.info/blago/TangraPlay/pulls/5
pull/6/head
Blagovest Petrov 4 years ago
parent
commit
ae2f076563
  1. 17
      AboutProgram.qml
  2. BIN
      Resources/KellySlab-Regular.ttf
  3. BIN
      Resources/logo.png
  4. 8
      fetchshowid.cpp
  5. 2
      fetchshowid.h
  6. 99
      main.qml
  7. 1
      qml.qrc

17
AboutProgram.qml

@ -21,7 +21,8 @@ Dialog {
id: element id: element
x: 0 x: 0
y: 8 y: 8
text: qsTr("TangraPlay v0.1 Alpha") text: qsTr("TangraPlay v0.5 Beta")
font.family: mainfont.name
font.bold: true font.bold: true
font.pixelSize: 33 font.pixelSize: 33
} }
@ -33,6 +34,7 @@ Dialog {
width: 216 width: 216
height: 61 height: 61
text: qsTr("(Винаги съм искал да направя софтуер с диалогов прозорец като mIRC )") text: qsTr("(Винаги съм искал да направя софтуер с диалогов прозорец като mIRC )")
font.family: mainfont.name
wrapMode: Text.WrapAtWordBoundaryOrAnywhere wrapMode: Text.WrapAtWordBoundaryOrAnywhere
elide: Text.ElideLeft elide: Text.ElideLeft
font.pixelSize: 12 font.pixelSize: 12
@ -43,8 +45,9 @@ Dialog {
x: 28 x: 28
y: 172 y: 172
width: 354 width: 354
height: 36 height: 74
text: qsTr("© 2020 Благовест Петров ( https://petrovs.info ) . Кодът е лиценциран под GNU GPV v3.0. ") text: qsTr("© 2020 Благовест Петров ( https://petrovs.info ) . Кодът е лиценциран под GNU GPL v3.0. \n Шрифтът е \"Kelly Slab\" и е взет от Google Fonts. Лицензиран е под OFL лиценз.")
font.family: mainfont.name
wrapMode: Text.WrapAtWordBoundaryOrAnywhere wrapMode: Text.WrapAtWordBoundaryOrAnywhere
font.pixelSize: 12 font.pixelSize: 12
} }
@ -52,10 +55,11 @@ Dialog {
Text { Text {
id: element3 id: element3
x: 28 x: 28
y: 222 y: 271
width: 354 width: 354
height: 36 height: 36
text: qsTr("Всички лога, графики и името \"Tangra Mega Rock\" са собственост на радио Тангра.") text: qsTr("Всички лога, графики и името \"Tangra Mega Rock\" са собственост на радио Тангра.")
font.family: mainfont.name
font.pixelSize: 12 font.pixelSize: 12
wrapMode: Text.WrapAtWordBoundaryOrAnywhere wrapMode: Text.WrapAtWordBoundaryOrAnywhere
} }
@ -63,10 +67,11 @@ Dialog {
Text { Text {
id: element4 id: element4
x: 28 x: 28
y: 276 y: 323
width: 354 width: 354
height: 36 height: 36
text: qsTr("Този софтуер e направен напълно с некомерсиална цел не е свързан по никакъв начин с Рок Радио Tangra Mega Rock") text: qsTr("Този софтуер e направен напълно с некомерсиална цел и не е свързан по никакъв начин с Рок Радио Tangra Mega Rock")
font.family: mainfont.name
font.pixelSize: 12 font.pixelSize: 12
wrapMode: Text.WrapAtWordBoundaryOrAnywhere wrapMode: Text.WrapAtWordBoundaryOrAnywhere
} }

BIN
Resources/KellySlab-Regular.ttf

Binary file not shown.

BIN
Resources/logo.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 46 KiB

8
fetchshowid.cpp

@ -11,13 +11,5 @@ FetchShowID::FetchShowID()
//int FetchShowID::Fetch() { //int FetchShowID::Fetch() {
// QNetworkAccessManager *manager = new QNetworkAccessManager(this); // QNetworkAccessManager *manager = new QNetworkAccessManager(this);
// QObject::connect(manager, &QNetworkAccessManager::finished, this, [=](QNetworkReply *reply) {
// if (reply->error()) {
// qDebug() << reply->errorString();
// return;
// }
// QString answer = reply->readAll();
// }
//} //}

2
fetchshowid.h

@ -6,7 +6,7 @@ class FetchShowID
{ {
public: public:
FetchShowID(); FetchShowID();
// int FetchShowID::Fetch(); // int Fetch();
}; };
#endif // FETCHSHOWID_H #endif // FETCHSHOWID_H

99
main.qml

@ -11,6 +11,8 @@ Window {
height: 480 height: 480
flags: Qt.FramelessWindowHint flags: Qt.FramelessWindowHint
FontLoader { id: mainfont; source: "Resources/KellySlab-Regular.ttf" }
SystemTrayIcon { SystemTrayIcon {
visible: true visible: true
icon.source: "Resources/tangra.ico" icon.source: "Resources/tangra.ico"
@ -118,6 +120,7 @@ Window {
id: appTitle id: appTitle
anchors.left: buttonMinimize.right anchors.left: buttonMinimize.right
text: qsTr("TangraPlay") text: qsTr("TangraPlay")
font.family: mainfont.name
font.pixelSize: 20 font.pixelSize: 20
font.bold: true font.bold: true
color: "#f9c620" color: "#f9c620"
@ -134,53 +137,62 @@ Window {
height: 175 height: 175
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
source: "Resources/logo.png" source: "Resources/logo.png"
MouseArea {
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
onPressed: {
Qt.openUrlExternally("http://radiotangra.com")
}
}
} }
Text {
id: element
x: 17
y: 68
text: qsTr("Качество:")
font.bold: true
color: "#f9c620"
styleColor: "#f9c620"
horizontalAlignment: Text.AlignHCenter
font.pixelSize: 20
}
Rectangle {
id: buttonHighQuality
color: "#f9c620"
x: 17
y: 102
width: 100
height: 34
Text {
anchors.centerIn: parent
id: element1
text: qsTr("ВИСОКО")
color: "#000000"
font.pixelSize: 20
horizontalAlignment: Text.AlignHCenter
font.bold: true
}
}
Rectangle { // Text {
id: buttonLowQuality // id: element
color: "transparent" // x: 17
x: 24 // y: 68
y: 146 // text: qsTr("Качество:")
width: 100 // font.bold: true
height: 34 // color: "#f9c620"
Text { // styleColor: "#f9c620"
text: qsTr("НИСКО") // horizontalAlignment: Text.AlignHCenter
color: "#f9c620" // font.pixelSize: 20
horizontalAlignment: Text.AlignHCenter // }
font.pixelSize: 20
font.bold: true // Rectangle {
} // id: buttonHighQuality
} // color: "#f9c620"
// x: 17
// y: 102
// width: 100
// height: 34
// Text {
// anchors.centerIn: parent
// id: element1
// text: qsTr("ВИСОКО")
// color: "#000000"
// font.pixelSize: 20
// horizontalAlignment: Text.AlignHCenter
// font.bold: true
// }
// }
// Rectangle {
// id: buttonLowQuality
// color: "transparent"
// x: 24
// y: 146
// width: 100
// height: 34
// Text {
// text: qsTr("НИСКО")
// color: "#f9c620"
// horizontalAlignment: Text.AlignHCenter
// font.pixelSize: 20
// font.bold: true
// }
// }
MediaButton { MediaButton {
id: playPause id: playPause
@ -201,6 +213,7 @@ Window {
y: 455 y: 455
text: qsTr("Относно програмата") text: qsTr("Относно програмата")
font.pixelSize: 12 font.pixelSize: 12
font.family: mainfont.name
color: "#f9c620" color: "#f9c620"
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent

1
qml.qrc

@ -13,5 +13,6 @@
<file>AboutProgram.qml</file> <file>AboutProgram.qml</file>
<file>Resources/blago.png</file> <file>Resources/blago.png</file>
<file>Resources/tangra.ico</file> <file>Resources/tangra.ico</file>
<file>Resources/KellySlab-Regular.ttf</file>
</qresource> </qresource>
</RCC> </RCC>

Loading…
Cancel
Save