Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

button size && CustomAvatarEmptyArea text align tweak #1976

Merged
merged 2 commits into from
Dec 24, 2024

Conversation

kegechen
Copy link
Contributor

  • button size tweak
  • fix translation missing
  • label text AlignHCenter

pms: Bug-297099, Bug-297053

@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: caixr23, kegechen, mhduiy

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

label text AlignHCenter
pms: Bug-297099
- button size tweak
- fix translation missing

pms: Bug-297053
@deepin-ci-robot
Copy link

deepin pr auto review

代码审查意见:

  1. AccountSettings.qml文件中,新增的FontMetrics对象fm被用于计算按钮的implicitWidthimplicitHeight。这是一个好的做法,因为它确保了按钮的大小会根据文本内容动态调整。但是,如果fm对象在其他地方也被使用,建议将其移动到更合适的位置,以避免重复定义。

  2. CustomAvatarEmpatyArea.qml文件中,新增的horizontalAlignment: Text.AlignHCenter属性确保了文本在水平方向上居中对齐。这是一个好的做法,因为它提高了界面的可读性。

  3. LangAndFormat.qmlTimeAndDate.qml文件中,新增的FontMetrics对象fm被用于计算按钮的implicitWidthimplicitHeight。这同样是一个好的做法,因为它确保了按钮的大小会根据文本内容动态调整。

  4. dde-control-center_zh_CN.ts文件中,翻译文本已经被更新。但是,建议在翻译过程中保持一致性,确保所有翻译都遵循相同的格式和风格。

  5. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,新增的implicitWidthimplicitHeight属性被设置为fm.advanceWidth(text) + 1230。这里的1230是硬编码的值,建议将其定义为常量,以便于维护和修改。

  6. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,Loader组件的active属性被设置为false,这意味着它们默认情况下是隐藏的。如果这些组件在页面加载时需要显示,建议在页面加载时将其active属性设置为true

  7. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,Button组件的onClicked事件处理程序中,dccData.requestCreateGroup(settings.userId)groupview.positionViewAtEnd()方法被调用。建议在这些方法调用之前添加错误处理,以防止在方法执行失败时导致应用程序崩溃。

  8. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,Button组件的text属性被设置为qsTr("Add new user")qsTr("Delete current account")qsTr("Group setting")qsTr("Add group")。建议在翻译过程中保持一致性,确保所有文本都遵循相同的格式和风格。

  9. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,Button组件的text属性被设置为qsTr("add")。建议在翻译过程中保持一致性,确保所有文本都遵循相同的格式和风格。

  10. AccountSettings.qmlLangAndFormat.qmlTimeAndDate.qml文件中,Button组件的text属性被设置为qsTr("Settings")。建议在翻译过程中保持一致性,确保所有文本都遵循相同的格式和风格。

@kegechen
Copy link
Contributor Author

/forcemerge

@deepin-bot
Copy link

deepin-bot bot commented Dec 24, 2024

This pr force merged! (status: blocked)

@deepin-bot deepin-bot bot merged commit 3d14c4c into linuxdeepin:master Dec 24, 2024
15 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants