Added a send message button on header frame.

set default border stylesheet for the Avatar Label.

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7935 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
defnax 2015-02-10 01:14:44 +00:00
parent d89cee8bdd
commit 05d25a83d5
6 changed files with 103 additions and 13 deletions

View file

@ -147,8 +147,10 @@ IdDialog::IdDialog(QWidget *parent) :
connect(ui->filterLineEdit, SIGNAL(textChanged(QString)), this, SLOT(filterChanged(QString))); connect(ui->filterLineEdit, SIGNAL(textChanged(QString)), this, SLOT(filterChanged(QString)));
connect(ui->repModButton, SIGNAL(clicked()), this, SLOT(modifyReputation())); connect(ui->repModButton, SIGNAL(clicked()), this, SLOT(modifyReputation()));
ui->headerFrame->setHeaderImage(QPixmap(":/images/user/friends64.png")); connect(ui->messageButton, SIGNAL(clicked()), this, SLOT(sendMsg()));
ui->headerFrame->setHeaderText(tr("People"));
ui->avlabel->setPixmap(QPixmap(":/images/user/friends64.png"));
ui->headerTextLabel->setText(tr("People"));
/* Initialize splitter */ /* Initialize splitter */
ui->splitter->setStretchFactor(0, 1); ui->splitter->setStretchFactor(0, 1);
@ -564,7 +566,7 @@ void IdDialog::insertIdDetails(uint32_t token)
//ui->lineEdit_GpgHash->setText(QString::fromStdString(data.mPgpIdHash.toStdString())); //ui->lineEdit_GpgHash->setText(QString::fromStdString(data.mPgpIdHash.toStdString()));
ui->lineEdit_GpgId->setText(QString::fromStdString(data.mPgpId.toStdString())); ui->lineEdit_GpgId->setText(QString::fromStdString(data.mPgpId.toStdString()));
ui->headerFrame->setHeaderText(QString::fromUtf8(data.mMeta.mGroupName.c_str())); ui->headerTextLabel->setText(QString::fromUtf8(data.mMeta.mGroupName.c_str()));
QPixmap pixmap ; QPixmap pixmap ;
@ -574,7 +576,7 @@ void IdDialog::insertIdDetails(uint32_t token)
#ifdef ID_DEBUG #ifdef ID_DEBUG
std::cerr << "Setting header frame image : " << pix.width() << " x " << pix.height() << std::endl; std::cerr << "Setting header frame image : " << pix.width() << " x " << pix.height() << std::endl;
#endif #endif
ui->headerFrame->setHeaderImage(QPixmap(":/images/user/personal64.png")); ui->avlabel->setPixmap(pixmap);
ui->avatarLabel->setPixmap(pixmap); ui->avatarLabel->setPixmap(pixmap);
if (data.mPgpKnown) if (data.mPgpKnown)
@ -958,6 +960,7 @@ void IdDialog::IdListCustomPopupMenu( QPoint )
{ {
QMenu contextMnu( this ); QMenu contextMnu( this );
std::list<RsGxsId> own_identities ; std::list<RsGxsId> own_identities ;
rsIdentity->getOwnIds(own_identities) ; rsIdentity->getOwnIds(own_identities) ;

View file

@ -215,13 +215,85 @@
<widget class="QWidget" name="layoutWidget"> <widget class="QWidget" name="layoutWidget">
<layout class="QVBoxLayout" name="verticalLayout_4"> <layout class="QVBoxLayout" name="verticalLayout_4">
<item> <item>
<widget class="HeaderFrame" name="headerFrame"> <widget class="QFrame" name="headerFrame">
<property name="frameShape"> <property name="frameShape">
<enum>QFrame::StyledPanel</enum> <enum>QFrame::StyledPanel</enum>
</property> </property>
<property name="frameShadow"> <property name="frameShadow">
<enum>QFrame::Raised</enum> <enum>QFrame::Raised</enum>
</property> </property>
<layout class="QGridLayout" name="gridLayout_4">
<property name="horizontalSpacing">
<number>12</number>
</property>
<item row="0" column="0" rowspan="2">
<widget class="QLabel" name="avlabel">
<property name="minimumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="text">
<string/>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="1" rowspan="2" colspan="2">
<widget class="StyledLabel" name="headerTextLabel">
<property name="text">
<string>People</string>
</property>
</widget>
</item>
<item row="0" column="3" rowspan="2">
<widget class="QToolButton" name="messageButton">
<property name="minimumSize">
<size>
<width>48</width>
<height>48</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>48</width>
<height>48</height>
</size>
</property>
<property name="toolTip">
<string>Send Message</string>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../images.qrc">
<normaloff>:/images/mail-message-new.png</normaloff>:/images/mail-message-new.png</iconset>
</property>
<property name="iconSize">
<size>
<width>48</width>
<height>48</height>
</size>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget> </widget>
</item> </item>
<item> <item>
@ -635,12 +707,6 @@
<extends>QLabel</extends> <extends>QLabel</extends>
<header>gui/common/StyledLabel.h</header> <header>gui/common/StyledLabel.h</header>
</customwidget> </customwidget>
<customwidget>
<class>HeaderFrame</class>
<extends>QFrame</extends>
<header>gui/common/HeaderFrame.h</header>
<container>1</container>
</customwidget>
</customwidgets> </customwidgets>
<tabstops> <tabstops>
<tabstop>todoPushButton</tabstop> <tabstop>todoPushButton</tabstop>

View file

@ -353,6 +353,7 @@
<file>images/logobar/logo_bar_start.png</file> <file>images/logobar/logo_bar_start.png</file>
<file>images/logobar/rslogo.png</file> <file>images/logobar/rslogo.png</file>
<file>images/logobar/rslogo2.png</file> <file>images/logobar/rslogo2.png</file>
<file>images/mail-message-new.png</file>
<file>images/mail-signed.png</file> <file>images/mail-signed.png</file>
<file>images/mail-signature-unknown.png</file> <file>images/mail-signature-unknown.png</file>
<file>images/mail_delete.png</file> <file>images/mail_delete.png</file>

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

View file

@ -597,3 +597,18 @@ QLabel#avatarLabel{
border: 2px solid #CCCCCC; border: 2px solid #CCCCCC;
border-radius: 4px; border-radius: 4px;
} }
IdDialog QFrame#headerFrame {
background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 #9BDBF9, stop:1 #1592CD);
border: 1px;
border-radius: 4px;
}
IdDialog QLabel#headerTextLabel {
color: rgb(255, 255, 255);
}
IdDialog QLabel#avlabel {
border: 4px solid white;
border-radius: 10px;
}

View file

@ -177,3 +177,8 @@ NetworkDialog
qproperty-backgroundColorHasSignedMe: rgb(178, 66, 178); qproperty-backgroundColorHasSignedMe: rgb(178, 66, 178);
qproperty-backgroundColorDenied: lightGray; qproperty-backgroundColorDenied: lightGray;
} }
QLabel#headerTextLabel
{
qproperty-fontSizeFactor: 225;
}