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

Hightlight properly library items #1062

Closed
wants to merge 1 commit into from

Conversation

MeerIsmailAli
Copy link

@MeerIsmailAli MeerIsmailAli commented Mar 19, 2024

Changes in contentmanagerdelgate inside the paint for hovering

Fixes #999

@kelson42
Copy link
Collaborator

@MeerIsmailAli Which issue does it fix? Please open an issue explain the nature of the bug/enhancement.

@MeerIsmailAli
Copy link
Author

@kelson42 mr for issue reference #999 (Not the whole line in library view is highlighted #999)

@kelson42
Copy link
Collaborator

@MeerIsmailAli Thank you very much for your PR and sorry for the late feedback my side. We will review your PR from both functional and code perspective. I have also rebased your PR on latest main origin HEAD, don't be surprised about that!

@kelson42 kelson42 changed the title updates in managerview UI Hightlight properly library items Mar 30, 2024
@kelson42
Copy link
Collaborator

@MeerIsmailAli From a functional point of vue, it works fine, but can we secure as well the line between each item goes from the very left to the very right, like in the mockup?
image

@MeerIsmailAli
Copy link
Author

MeerIsmailAli commented Mar 31, 2024

extending border

is this sufficient @kelson42 ?
made a new commit for the same

@kelson42
Copy link
Collaborator

kelson42 commented Apr 6, 2024

@MeerIsmailAli Thank you, but why the separator does not go on the very left below the arrows?

@kelson42
Copy link
Collaborator

@MeerIsmailAli Hi, do you still plan to cpmplete the last small step so we can merge?

@MeerIsmailAli
Copy link
Author

@kelson42 ok let me look into it

Copy link
Collaborator

@kelson42 kelson42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MeerIsmailAli Thank you for your last commits, now it looks good from grey background perspective and separator... but you have introduced a regression. The description font is now partly in grey, it should stay the same color like before. See my screenshot showing the problem:
image

The git revision log is pretty messy because of multiple commits and also merge of main branch in your branch. Please put all your changes in one commit... on the top of current HEAD of main branch. Then we could start with technical code review.

@kelson42
Copy link
Collaborator

@MeerIsmailAli Any update? We are almost there!

@MeerIsmailAli
Copy link
Author

sorry for the delay @kelson42 , made a new pr with the requested changes(fix for issue #1062 #1095)

@kelson42 kelson42 mentioned this pull request Apr 30, 2024
@MeerIsmailAli
Copy link
Author

sorry for the confusion tried to consolidate all changes in a new pr, but removed it now , made the recent commits to handle the recent regression.

@kelson42
Copy link
Collaborator

kelson42 commented May 1, 2024

@MeerIsmailAli Can you please rebase on the HEAD of main branch please?

@MeerIsmailAli
Copy link
Author

MeerIsmailAli commented May 1, 2024

@kelson42 my branch has been rebased with the main branch, im not sure what exactly im missing. Let me know if theres any changes needed.

@kelson42
Copy link
Collaborator

kelson42 commented May 4, 2024

@MeerIsmailAli You don't have rebased on main, You have merged main in the feature branch which generates a messy git revision log.
@veloman-yunkan Whatever how the git revision log, could you please give a code review?

Comment on lines 185 to 189
if (option.state & QStyle::State_MouseOver) {
baseButton->setStyleSheet("background-color: #eaecf0;"
"border: 0;"
"font-weight: bold;"
"font-family: Selawik;"
"border-bottom: 1px solid #cccccc;"
"color: blue;"
"margin: 0;");
baseButton->style()->drawControl( QStyle::CE_PushButton, &button, painter, baseButton.data());
}else{
baseButton->setStyleSheet("background-color: white;"
"border: 0;"
"font-weight: bold;"
"font-family: Selawik;"
"border-bottom: 1px solid #cccccc;"
"color: blue;"
"margin: 0;");
baseButton->style()->drawControl( QStyle::CE_PushButton, &button, painter, baseButton.data());
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Too much code duplication between the two branches. At least the drawControl() line can be moved out.

Then the only difference between the stylesheet strings is the value of background colour. The question is if you had to explicitly specify the other parameters (using their implicitly default values in this context) just because it is impossible to separately set just the background colour.

In any case if the stylesheet string must be provided fully its common part should be separated into a constant.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@veloman-yunkan thanks for your suggestions, implemented them in the latest commit.

@kelson42
Copy link
Collaborator

@MeerIsmailAli Any update? We would really like to merge your PR.

@veloman-yunkan
Copy link
Collaborator

I cleared the mess with the history of this PR. Then an attempt to rebase it on main failed since conflicting changes have been made in src/contentmanagerdelegate.cpp. I am now going to complete the PR on my own.

@kelson42
Copy link
Collaborator

Superseeded by #1109

@kelson42 kelson42 closed this May 14, 2024
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.

Not the whole line in library view is highlighted
3 participants