Compare commits

..

7 Commits

Author SHA1 Message Date
朱子楚\zhuzi b3e26d17a2 update 2024-03-09 23:42:01 +08:00
朱子楚\zhuzi 0e55f31fe2 Merge branch 'main' of https://github.com/zhuzichu520/FluentUI 2024-03-09 22:39:39 +08:00
朱子楚\zhuzi f624007fec update 2024-03-09 22:39:34 +08:00
zhuzichu 65844ef105
Merge pull request #456 from mentalfl0w/patch-1
CMakeLists: simplify code.
2024-03-09 22:39:08 +08:00
Dylan Liu 799df5c644
CMakeLists: simplify code. 2024-03-09 22:33:51 +08:00
朱子楚\zhuzi afd888d7a0 update 2024-03-09 22:26:21 +08:00
朱子楚\zhuzi 1d5f8772e1 update 2024-03-09 22:19:10 +08:00
41 changed files with 89 additions and 89 deletions

View File

@ -18,10 +18,8 @@ option(FLUENTUI_BUILD_STATIC_LIB "Build static library." OFF)
find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core)
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core)
set(QT_SDK_DIR "${Qt${QT_VERSION_MAJOR}_DIR}")
cmake_path(GET QT_SDK_DIR PARENT_PATH QT_SDK_DIR)
cmake_path(GET QT_SDK_DIR PARENT_PATH QT_SDK_DIR)
cmake_path(GET QT_SDK_DIR PARENT_PATH QT_SDK_DIR)
set(QT_SDK_DIR "${Qt${QT_VERSION_MAJOR}_DIR}/../../..")
cmake_path(SET QT_SDK_DIR NORMALIZE ${QT_SDK_DIR})
#QML<QT_SDK_DIR_PATH>\qml\FluentUI
set(FLUENTUI_QML_PLUGIN_DIRECTORY "" CACHE PATH "Path to FluentUI plugin")

View File

@ -680,7 +680,7 @@
<location filename="qml/window/MainWindow.qml" line="118"/>
<location filename="qml-Qt6/window/MainWindow.qml" line="118"/>
<source>Open in Separate Window</source>
<translation type="unfinished"></translation>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/window/MainWindow.qml" line="215"/>

View File

@ -62,7 +62,7 @@ FluContentPage {
anchors.horizontalCenter: parent.horizontalCenter
anchors.top: item_icon.bottom
width:parent.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text: modelData.name
horizontalAlignment: Text.AlignHCenter
}

View File

@ -23,7 +23,7 @@ FluScrollablePage{
right: parent.right
}
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
width: parent.width
text: qsTr("It usually appears in the upper right corner of the notification icon or avatar to display the number of messages that need to be processed")
}

View File

@ -64,7 +64,7 @@ FluScrollablePage{
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
text: qsTr("Permit me to observe: the late emperor was taken from us before he could finish his life`s work, the restoration of Han. Today, the empire is still divided in three, and our very survival is threatened. Yet still the officials at court and the soldiers throughout the realm remain loyal to you, your majesty. Because they remember the late emperor, all of them, and they wish to repay his kindness in service to you. This is the moment to extend your divine influence, to honour the memory of the late Emperor and strengthen the morale of your officers. It is not time to listen to bad advice, or close your ears to the suggestions of loyal men.
The court and the administration are as one. Both must be judged by one standard. Those who are loyal and good must get what they deserve, but so must the evil-doers who break the law. This will demonstrate the justice of your rule. There cannot be one law for the court and another for the administration.
@ -97,7 +97,7 @@ My only desire is to be permitted to drive out the traitors and restore the Han.
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
text: qsTr("Permit me to observe: the late emperor was taken from us before he could finish his life`s work...")
}

View File

@ -118,7 +118,7 @@ FluScrollablePage{
Layout.leftMargin: 20
color: FluColors.Grey120
font.pixelSize: 12
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
}
}
FluIcon{
@ -214,7 +214,7 @@ FluScrollablePage{
id:item_desc
text:desc
color:FluColors.Grey120
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
elide: Text.ElideRight
font: FluTextStyle.Caption
maximumLineCount: 2

View File

@ -552,7 +552,7 @@ FluContentPage{
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
}
}

View File

@ -23,7 +23,7 @@ FluScrollablePage{
Component{
id:com_lable
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
font.bold: true
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.lable
@ -41,7 +41,7 @@ FluScrollablePage{
Component{
id:com_text
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.text
font.bold: true

View File

@ -44,7 +44,7 @@ FluWindow {
leftMargin: 10
rightMargin: 10
}
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text: qsTr("We apologize for the inconvenience caused by an unexpected error")
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter

View File

@ -32,7 +32,7 @@ FluWindow {
text:loader.itemLodaer().sourceComponent.errorString()
color:"red"
anchors.fill: parent
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 20
verticalAlignment: Qt.AlignVCenter
horizontalAlignment: Qt.AlignHCenter

View File

@ -13,8 +13,8 @@ FluWindow {
id:window
title: "FluentUI"
width: 960
height: 600
width: 1000
height: 680
minimumWidth: 520
minimumHeight: 200
launchMode: FluWindowType.SingleTask
@ -112,11 +112,10 @@ FluWindow {
Component{
id: nav_item_right_menu
FluMenu{
id: menu
width: 130
width: 186
FluMenuItem{
text: qsTr("Open in Separate Window")
visible: true
font.pixelSize: 12
onClicked: {
FluApp.navigate("/pageWindow",{title:modelData.title,url:modelData.url})
}

View File

@ -22,7 +22,7 @@ FluWindow {
}
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
anchors{
left: parent.left
right: parent.right

View File

@ -62,7 +62,7 @@ FluContentPage {
anchors.horizontalCenter: parent.horizontalCenter
anchors.top: item_icon.bottom
width:parent.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text: modelData.name
horizontalAlignment: Text.AlignHCenter
}

View File

@ -23,7 +23,7 @@ FluScrollablePage{
right: parent.right
}
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
width: parent.width
text: qsTr("It usually appears in the upper right corner of the notification icon or avatar to display the number of messages that need to be processed")
}

View File

@ -64,7 +64,7 @@ FluScrollablePage{
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
text: qsTr("Permit me to observe: the late emperor was taken from us before he could finish his life`s work, the restoration of Han. Today, the empire is still divided in three, and our very survival is threatened. Yet still the officials at court and the soldiers throughout the realm remain loyal to you, your majesty. Because they remember the late emperor, all of them, and they wish to repay his kindness in service to you. This is the moment to extend your divine influence, to honour the memory of the late Emperor and strengthen the morale of your officers. It is not time to listen to bad advice, or close your ears to the suggestions of loyal men.
The court and the administration are as one. Both must be judged by one standard. Those who are loyal and good must get what they deserve, but so must the evil-doers who break the law. This will demonstrate the justice of your rule. There cannot be one law for the court and another for the administration.
@ -97,7 +97,7 @@ My only desire is to be permitted to drive out the traitors and restore the Han.
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
text: qsTr("Permit me to observe: the late emperor was taken from us before he could finish his life`s work...")
}

View File

@ -118,7 +118,7 @@ FluScrollablePage{
Layout.leftMargin: 20
color: FluColors.Grey120
font.pixelSize: 12
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
}
}
FluIcon{
@ -214,7 +214,7 @@ FluScrollablePage{
id:item_desc
text:desc
color:FluColors.Grey120
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
elide: Text.ElideRight
font: FluTextStyle.Caption
maximumLineCount: 2

View File

@ -552,7 +552,7 @@ FluContentPage{
FluText{
id:text_info
width: scrollview.width
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 14
}
}

View File

@ -23,7 +23,7 @@ FluScrollablePage{
Component{
id:com_lable
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
font.bold: true
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.lable
@ -41,7 +41,7 @@ FluScrollablePage{
Component{
id:com_text
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.text
font.bold: true

View File

@ -44,7 +44,7 @@ FluWindow {
leftMargin: 10
rightMargin: 10
}
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text: qsTr("We apologize for the inconvenience caused by an unexpected error")
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter

View File

@ -32,7 +32,7 @@ FluWindow {
text:loader.itemLodaer().sourceComponent.errorString()
color:"red"
anchors.fill: parent
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 20
verticalAlignment: Qt.AlignVCenter
horizontalAlignment: Qt.AlignHCenter

View File

@ -13,8 +13,8 @@ FluWindow {
id:window
title: "FluentUI"
width: 960
height: 600
width: 1000
height: 680
minimumWidth: 520
minimumHeight: 200
launchMode: FluWindowType.SingleTask
@ -112,11 +112,10 @@ FluWindow {
Component{
id: nav_item_right_menu
FluMenu{
id: menu
width: 130
width: 186
FluMenuItem{
text: qsTr("Open in Separate Window")
visible: true
font.pixelSize: 12
onClicked: {
FluApp.navigate("/pageWindow",{title:modelData.title,url:modelData.url})
}

View File

@ -22,7 +22,7 @@ FluWindow {
}
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
anchors{
left: parent.left
right: parent.right

View File

@ -20,12 +20,12 @@ static inline QByteArray qtNativeEventType()
static inline bool isCompositionEnabled(){
typedef HRESULT (WINAPI* DwmIsCompositionEnabledPtr)(BOOL *pfEnabled);
HMODULE module = LoadLibraryW(L"dwmapi.dll");
HMODULE module = ::LoadLibraryW(L"dwmapi.dll");
if (module)
{
BOOL composition_enabled = false;
DwmIsCompositionEnabledPtr dwm_is_composition_enabled;
dwm_is_composition_enabled= reinterpret_cast<DwmIsCompositionEnabledPtr>(GetProcAddress(module, "DwmIsCompositionEnabled"));
dwm_is_composition_enabled= reinterpret_cast<DwmIsCompositionEnabledPtr>(::GetProcAddress(module, "DwmIsCompositionEnabled"));
if (dwm_is_composition_enabled)
{
dwm_is_composition_enabled(&composition_enabled);
@ -64,7 +64,7 @@ bool FramelessEventFilter::nativeEventFilter(const QByteArray &eventType, void *
if (wp != nullptr && (wp->flags & SWP_NOSIZE) == 0)
{
wp->flags |= SWP_NOCOPYBITS;
*result = 0;
*result = ::DefWindowProcW(hwnd, uMsg, wParam, lParam);
return true;
}
return false;
@ -82,7 +82,7 @@ bool FramelessEventFilter::nativeEventFilter(const QByteArray &eventType, void *
return true;
}
int offsetSize = 0;
bool isMaximum = IsZoomed(hwnd);
bool isMaximum = ::IsZoomed(hwnd);
offsetXY = QPoint(abs(clientRect->left - originalLeft),abs(clientRect->top - originalTop));
if(isMaximum || _helper->fullScreen()){
_helper->setOriginalPos(QPoint(originalLeft,originalTop));
@ -171,7 +171,7 @@ bool FramelessEventFilter::nativeEventFilter(const QByteArray &eventType, void *
*result = FALSE;
return true;
}else if(uMsg == WM_NCACTIVATE){
*result = DefWindowProcW(hwnd, WM_NCACTIVATE, wParam, -1);
*result = ::DefWindowProcW(hwnd, WM_NCACTIVATE, wParam, -1);
return true;
}else if(uMsg == WM_GETMINMAXINFO){
#if QT_VERSION < QT_VERSION_CHECK(6,2,4)
@ -322,21 +322,21 @@ void FluFramelessHelper::componentComplete(){
HWND hwnd = reinterpret_cast<HWND>(window->winId());
DWORD style = ::GetWindowLong(hwnd, GWL_STYLE);
if(resizeable()){
SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_MAXIMIZEBOX | WS_THICKFRAME);
::SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_MAXIMIZEBOX | WS_THICKFRAME);
}else{
SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_THICKFRAME);
::SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_THICKFRAME);
}
LONG exstyle = ::GetWindowLong(hwnd, GWL_EXSTYLE);
exstyle = exstyle | WS_EX_LAYERED;
SetWindowLongPtr(hwnd, GWL_EXSTYLE, exstyle);
SetLayeredWindowAttributes(hwnd, RGB(251, 255, 242), 0, LWA_COLORKEY);
::SetWindowLongPtr(hwnd, GWL_EXSTYLE, exstyle);
::SetLayeredWindowAttributes(hwnd, RGB(251, 255, 242), 0, LWA_COLORKEY);
connect(window,&QQuickWindow::activeChanged,this,[this,hwnd]{
if(this->window->isActive()){
LONG exstyle = ::GetWindowLong(hwnd, GWL_EXSTYLE);
if(exstyle & WS_EX_LAYERED){
exstyle = exstyle &~ WS_EX_LAYERED;
SetWindowLongPtr(hwnd, GWL_EXSTYLE, exstyle);
SetWindowPos(hwnd,nullptr,0,0,0,0,SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_FRAMECHANGED);
::SetWindowLongPtr(hwnd, GWL_EXSTYLE, exstyle);
::SetWindowPos(hwnd,nullptr,0,0,0,0,SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_FRAMECHANGED);
}
}
});
@ -362,36 +362,36 @@ void FluFramelessHelper::componentComplete(){
void FluFramelessHelper::_onScreenChanged(){
#ifdef Q_OS_WIN
HWND hwnd = reinterpret_cast<HWND>(window->winId());
SetWindowPos(hwnd,0,0,0,0,0,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_NOOWNERZORDER);
RedrawWindow(hwnd, NULL, NULL, RDW_INVALIDATE | RDW_UPDATENOW);
::SetWindowPos(hwnd,0,0,0,0,0,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_NOOWNERZORDER);
::RedrawWindow(hwnd, NULL, NULL, RDW_INVALIDATE | RDW_UPDATENOW);
#endif
}
void FluFramelessHelper::showSystemMenu(QPoint point){
#ifdef Q_OS_WIN
HWND hwnd = reinterpret_cast<HWND>(window->winId());
DWORD style = GetWindowLongPtr(hwnd,GWL_STYLE);
SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_SYSMENU);
DWORD style = ::GetWindowLongPtr(hwnd,GWL_STYLE);
::SetWindowLongPtr(hwnd, GWL_STYLE, style | WS_SYSMENU);
const HMENU hMenu = ::GetSystemMenu(hwnd, FALSE);
if(maximized() || fullScreen()){
EnableMenuItem(hMenu,SC_MOVE,MFS_DISABLED);
EnableMenuItem(hMenu,SC_RESTORE,MFS_ENABLED);
::EnableMenuItem(hMenu,SC_MOVE,MFS_DISABLED);
::EnableMenuItem(hMenu,SC_RESTORE,MFS_ENABLED);
}else{
EnableMenuItem(hMenu,SC_MOVE,MFS_ENABLED);
EnableMenuItem(hMenu,SC_RESTORE,MFS_DISABLED);
::EnableMenuItem(hMenu,SC_MOVE,MFS_ENABLED);
::EnableMenuItem(hMenu,SC_RESTORE,MFS_DISABLED);
}
if(resizeable() && !maximized() && !fullScreen()){
EnableMenuItem(hMenu,SC_SIZE,MFS_ENABLED);
EnableMenuItem(hMenu,SC_MAXIMIZE,MFS_ENABLED);
::EnableMenuItem(hMenu,SC_SIZE,MFS_ENABLED);
::EnableMenuItem(hMenu,SC_MAXIMIZE,MFS_ENABLED);
}else{
EnableMenuItem(hMenu,SC_SIZE,MFS_DISABLED);
EnableMenuItem(hMenu,SC_MAXIMIZE,MFS_DISABLED);
::EnableMenuItem(hMenu,SC_SIZE,MFS_DISABLED);
::EnableMenuItem(hMenu,SC_MAXIMIZE,MFS_DISABLED);
}
const int result = TrackPopupMenu(hMenu, (TPM_RETURNCMD | (QGuiApplication::isRightToLeft() ? TPM_RIGHTALIGN : TPM_LEFTALIGN)), point.x()*window->devicePixelRatio(), point.y()*window->devicePixelRatio(), 0, hwnd, nullptr);
const int result = ::TrackPopupMenu(hMenu, (TPM_RETURNCMD | (QGuiApplication::isRightToLeft() ? TPM_RIGHTALIGN : TPM_LEFTALIGN)), point.x()*window->devicePixelRatio(), point.y()*window->devicePixelRatio(), 0, hwnd, nullptr);
if (result != FALSE) {
PostMessageW(hwnd, WM_SYSCOMMAND, result, 0);
::PostMessageW(hwnd, WM_SYSCOMMAND, result, 0);
}
SetWindowLongPtr(hwnd, GWL_STYLE, style &~ WS_SYSMENU);
::SetWindowLongPtr(hwnd, GWL_STYLE, style &~ WS_SYSMENU);
#endif
}
@ -400,9 +400,9 @@ void FluFramelessHelper::_onStayTopChange(){
#ifdef Q_OS_WIN
HWND hwnd = reinterpret_cast<HWND>(window->winId());
if(isStayTop){
SetWindowPos(hwnd, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);
::SetWindowPos(hwnd, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);
}else{
SetWindowPos(hwnd, HWND_NOTOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);
::SetWindowPos(hwnd, HWND_NOTOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);
}
#else
window->setFlag(Qt::WindowStaysOnTopHint,isStayTop);

View File

@ -41,7 +41,7 @@ FluPopup {
FluText{
id:text_message
font: FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text:message
width: parent.width
topPadding: 4
@ -67,7 +67,7 @@ FluPopup {
topPadding: 20
leftPadding: 20
rightPadding: 20
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
}
FluLoader{
sourceComponent: com_message

View File

@ -45,7 +45,7 @@ Button {
radius: parent.radius
anchors{
fill: parent
topMargin: control.enabled ? 1 : 0
topMargin: control.enabled ? 0 : 0
leftMargin: control.enabled ? 1 : 0
rightMargin: control.enabled ? 1 : 0
bottomMargin: control.enabled ? 2 : 0

View File

@ -192,13 +192,13 @@ FluObject {
spacing: 5
FluText{
text:_super.text
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
width: Math.min(implicitWidth,mcontrol.maxWidth)
}
FluText{
text: _super.moremsg
visible: _super.moremsg
wrapMode : Text.WordWrap
wrapMode : Text.WrapAnywhere
textColor: FluColors.Grey120
width: Math.min(implicitWidth,mcontrol.maxWidth)
}

View File

@ -40,6 +40,7 @@ T.MenuItem {
icon.height: 24
icon.color: control.palette.windowText
height: visible ? implicitHeight : 0
font:FluTextStyle.Body
Component{
id:com_icon
FluIcon{
@ -69,6 +70,7 @@ T.MenuItem {
FluText {
id:content_text
text: control.text
font: control.font
color: control.textColor
anchors.verticalCenter: parent.verticalCenter
}

View File

@ -20,7 +20,7 @@ TextArea{
return normalColor
}
font:FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 8
leftPadding: padding+4
renderType: FluTheme.nativeText ? Text.NativeRendering : Text.QtRendering

View File

@ -141,7 +141,7 @@ Rectangle {
id:item_text
text: String(display)
elide: Text.ElideRight
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
anchors{
fill: parent
leftMargin: 11

View File

@ -95,7 +95,7 @@ Item{
Component{
id:com_lable
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: {
if(modelData.lable){
@ -110,7 +110,7 @@ Item{
Component{
id:com_text
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.text
textFormat: Text.RichText

View File

@ -61,7 +61,7 @@ Button {
radius: parent.radius
anchors{
fill: parent
topMargin: checked && enabled ? 1 : 0
topMargin: checked && enabled ? 0 : 0
leftMargin: checked && enabled ? 1 : 0
rightMargin: checked && enabled ? 1 : 0
bottomMargin: checked && enabled ? 2 : 0

View File

@ -145,7 +145,7 @@ Popup{
FluText{
id: text_desc
font: FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
maximumLineCount: 4
elide: Text.ElideRight
text: d.step.description

View File

@ -41,7 +41,7 @@ FluPopup {
FluText{
id:text_message
font: FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
text:message
width: parent.width
topPadding: 4
@ -67,7 +67,7 @@ FluPopup {
topPadding: 20
leftPadding: 20
rightPadding: 20
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
}
FluLoader{
sourceComponent: com_message

View File

@ -46,7 +46,7 @@ Button {
radius: parent.radius
anchors{
fill: parent
topMargin: control.enabled ? 1 : 0
topMargin: control.enabled ? 0 : 0
leftMargin: control.enabled ? 1 : 0
rightMargin: control.enabled ? 1 : 0
bottomMargin: control.enabled ? 2 : 0

View File

@ -192,13 +192,13 @@ FluObject {
spacing: 5
FluText{
text:_super.text
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
width: Math.min(implicitWidth,mcontrol.maxWidth)
}
FluText{
text: _super.moremsg
visible: _super.moremsg
wrapMode : Text.WordWrap
wrapMode : Text.WrapAnywhere
textColor: FluColors.Grey120
width: Math.min(implicitWidth,mcontrol.maxWidth)
}

View File

@ -41,6 +41,7 @@ T.MenuItem {
icon.height: 24
icon.color: control.palette.windowText
height: visible ? implicitHeight : 0
font:FluTextStyle.Body
Component{
id:com_icon
FluIcon{
@ -70,6 +71,7 @@ T.MenuItem {
FluText {
id:content_text
text: control.text
font: control.font
color: control.textColor
anchors.verticalCenter: parent.verticalCenter
}

View File

@ -21,7 +21,7 @@ TextArea{
return normalColor
}
font:FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
padding: 8
leftPadding: padding+4
renderType: FluTheme.nativeText ? Text.NativeRendering : Text.QtRendering

View File

@ -142,7 +142,7 @@ Rectangle {
id:item_text
text: String(display)
elide: Text.ElideRight
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
anchors{
fill: parent
leftMargin: 11

View File

@ -95,7 +95,7 @@ Item{
Component{
id:com_lable
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: {
if(modelData.lable){
@ -110,7 +110,7 @@ Item{
Component{
id:com_text
FluText{
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
horizontalAlignment: isRight ? Qt.AlignRight : Qt.AlignLeft
text: modelData.text
textFormat: Text.RichText

View File

@ -57,7 +57,7 @@ Button {
radius: parent.radius
anchors{
fill: parent
topMargin: checked && enabled ? 1 : 0
topMargin: checked && enabled ? 0 : 0
leftMargin: checked && enabled ? 1 : 0
rightMargin: checked && enabled ? 1 : 0
bottomMargin: checked && enabled ? 2 : 0

View File

@ -145,7 +145,7 @@ Popup{
FluText{
id: text_desc
font: FluTextStyle.Body
wrapMode: Text.WordWrap
wrapMode: Text.WrapAnywhere
maximumLineCount: 4
elide: Text.ElideRight
text: d.step.description