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

Make scrolls of the Timeline thicker #2819

Merged
merged 7 commits into from
Jul 18, 2019
Merged

Conversation

SuslikV
Copy link
Contributor

@SuslikV SuslikV commented Jun 1, 2019

6px is too low value for the scrolls to handle it normally.
Hi-DPI displays can worsen situation.

The editor misses fast "hand" tool and default browser panning
tools is not very suitable for horizontal scrolling.
Application has few issues with zoom level and snapping, so
Ctrl + Mouse Wheel action is not useful too.
I'm using horizontal scrolling of the Timeline constantly, so
wish to have it slightly bigger controls to not aim precisely each
time I need to scroll the Timeline to the desirable position.

Before
Scrollbar_before

After
Scrollbar_after

6px is too low value for the scroll to handle it normally.
Make scrolls thicker and use DPI independent units to set
new values.
@ferdnyc
Copy link
Contributor

ferdnyc commented Jun 7, 2019

@SuslikV You should check out #1883, and the feedback that was provided there concerning the scrollbar in particular.

(Your change makes sense, I think it's a good one. But there's more that could be done, if you'd be interested. Some users made some excellent points about how the current scrollbar setup does and doesn't meet their needs, and how it could be better.)

@SuslikV
Copy link
Contributor Author

SuslikV commented Jun 8, 2019

Thank you for the feedback. I made small changes to styles. Now it looks like this:

OpenShot_Scrolls_after

The bright gradient border for whole scroll's track is added. It helps
to navigate OpenShot Timeline by scroll while preserving overall UI
styling.

The not used scroll's corner element removed.
@SuslikV
Copy link
Contributor Author

SuslikV commented Jul 1, 2019

Hmm, I found that width of the scrolls either mentioned or hardcoded in some other place of the Timeline too. Because with this change, the far right position of both the Timeline cursor and the horizontal scroll makes cursor broke apart into two elements shifted horizontally (the more width of the vertical scroll - the bigger shift is). It is connected to the Timeline's ruler size and scroll area size (unfortunately, Timeline cursor can be placed outside the scroll area in OpenShot, so someone used scroll's width as hardcoded stuff during development, I think).

Yeah, It needs more time to investigate.

SuslikV added 3 commits July 3, 2019 16:32
Only for clear reading - here object width is divided by 2 (to get
offset of the middle) and the central line is shifted by the same
amount.
At far right position of the horizontal scroll the cursor and
cursor-line breaks apart and gets amall horizontal shift. The canvas of
the ruler rendered slightly bigger to eliminate this shift.

When width of the vertical scroll was enlarged - the corresponding
final width of the ruler needs to be enlarged to fully cover new width
of the scroll bars.
@SuslikV
Copy link
Contributor Author

SuslikV commented Jul 3, 2019

I thought that here was my comment. I will write it again...
PR was updated to solve the shifting issue (see above). The simplest solution I found is to enlarge the canvas size of the ruler. Hardcoded stuff was left in the code, it still uses px instead of em units to represent the width. But should work well with the vertical scroll width used in this PR.

Copy link
Contributor

@ferdnyc ferdnyc left a comment

Choose a reason for hiding this comment

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

Finally got a chance to try this out. It looks great! I suggested some really minor changes, mostly coding-style stuff (and one visual tweak) but nothing that alters functionality. LGTM.

src/timeline/media/css/main.css Outdated Show resolved Hide resolved
src/timeline/media/css/main.css Show resolved Hide resolved
src/timeline/media/css/main.css Outdated Show resolved Hide resolved
src/timeline/media/css/main.css Outdated Show resolved Hide resolved
@SuslikV
Copy link
Contributor Author

SuslikV commented Jul 9, 2019

Style was fixed. Now, the screenshot I've posted earlier should actually reflect current PR state.

@ferdnyc ferdnyc requested a review from jonoomph July 9, 2019 16:57
@ferdnyc
Copy link
Contributor

ferdnyc commented Jul 9, 2019

I'm happy with this, I think it's a good change, and it addresses several issues with the existing scrollbars, including those raised by @qubodup on #1883. Tagging for review by @jonoomph.

SuslikV added 2 commits July 9, 2019 19:14
Remove background property from the track (to make track's corners
transparent).
Use box-shadow in scrollbar styling for code unification.
Use box-shadow instead of webkit specific property.
Mainly for code unification purposes.
@DylanC
Copy link
Collaborator

DylanC commented Jul 18, 2019

@ferdnyc - I could merge this in if you don't want to wait too long for a review. Seems like a safe change to merge.

@ferdnyc
Copy link
Contributor

ferdnyc commented Jul 18, 2019

@DylanC Works for me, as I said I'm good with it, I just felt it needed an extra pair of eyes. Yours appear functional! 👀

Thanks, @SuslikV !

@ferdnyc
Copy link
Contributor

ferdnyc commented Jul 18, 2019

(Hmmm, now how do I get my own PRs reviewed? 😇 I'm just not comfortable merging my own code into a collaborative project — not unless I can say that I believe it's literally impossible for it to cause any problems. I figure there's almost nothing so urgent that it can't wait on a second-party sanity check.)

@ferdnyc ferdnyc requested a review from DylanC July 18, 2019 09:50
Copy link
Collaborator

@DylanC DylanC left a comment

Choose a reason for hiding this comment

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

I'm happy with the commits. Nothing drastic here that would cause other issues from what I can see.

@DylanC
Copy link
Collaborator

DylanC commented Jul 18, 2019

@ferdnyc - I could review some of your PR's but I would only feel comfortable merging minor changes rather than major. I'll leave the bigger changes for @jonoomph to review.

(Edit) - As long as @jonoomph is happy for me to do so.

@DylanC DylanC merged commit 490e7ce into OpenShot:develop Jul 18, 2019
@SuslikV SuslikV deleted the patch-6 branch July 18, 2019 12:49
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.

3 participants