From 1cfbc4f6db7bef68ff0d620c48a73ba0934a8dea Mon Sep 17 00:00:00 2001 From: Joe Robinson Date: Fri, 14 Apr 2017 19:09:44 +0200 Subject: Add main channel UI --- IrcChannelForm.ui.qml | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 IrcChannelForm.ui.qml diff --git a/IrcChannelForm.ui.qml b/IrcChannelForm.ui.qml new file mode 100644 index 0000000..9e7ec37 --- /dev/null +++ b/IrcChannelForm.ui.qml @@ -0,0 +1,94 @@ +import QtQuick 2.7 +import QtQuick.Controls 2.0 +import QtQuick.Layouts 1.0 + +Item { + width: 640 + height: 480 + + RowLayout { + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 20 + anchors.top: parent.top + } + + Flickable { + id: flickable + width: 472 + height: 411 + x: 8 + y: 8 + TextArea { + objectName: "chat_area" + id: textArea + x: 8 + y: 8 + anchors.fill: parent + wrapMode: TextArea.Wrap + textFormat: TextEdit.RichText + font.family: "Source Code Pro" + font.pointSize: 11 + selectByMouse: true + } + ScrollBar.vertical: ScrollBar { } + } + + TextField { + signal send_to_irc + objectName: "input" + id: textField + x: 8 + y: 429 + width: 472 + height: 43 + selectByMouse: true + Keys.onEnterPressed: send_to_irc() + Keys.onReturnPressed: send_to_irc() + + } + + ListView { + id: nickListView + objectName: "nick_list" + x: 486 + y: 8 + width: 146 + height: 357 + delegate: Item { + x: 5 + width: 146 + height: 20 + Text { + text: name + anchors.verticalCenter: parent.verticalCenter + font.bold: true + font.family: "Source Code Pro" + font.pointSize: 11 + } + + } + model: ListModel { + id: nickListModel + } + + function add_nick(nick){ + nickListModel.append({name: nick}) + } +} + + Button { + objectName: "connect_button" + id: connect_button + x: 519 + y: 380 + text: qsTr("Connect") + } + + Button { + objectName: "send_button" + id: send_button + x: 519 + y: 429 + text: qsTr("Send") + } +} -- cgit v1.2.3