cgeo / cgeo

c:geo - The powerful Android geocaching app.
www.cgeo.org
Apache License 2.0
1.4k stars 567 forks source link

Migrate to material3 #14570

Open fm-sys opened 1 year ago

fm-sys commented 1 year ago

Tell us your idea!

Material Design v3 (aka Material You) is published for almost a year now, so I guess most early issues are solved meanwhile. Furthermore it becomes more and more common and gets adopted by other really popular apps.

What solution would you suggest?

Switch to m3

Is there an alternative?

Let c:geo look outdated again ;-)

Additional Information

01092023081132

Color usage: unnamed

eddiemuc commented 1 year ago

What does this mean implementation-wise? Is it "just" switching icons and a library (to use new GUI components), or is there more work to do?

fm-sys commented 1 year ago

The icons even doesn't have changed significantly. For sure, from time to time some icons get some small tweaks, but nothing we really have to care about.

In theory it's just changing the style parent from MaterialComponents to Material3, but probably it'll be a bit more work.

https://material.io/blog/migrating-material-3

Wer could implement DynamicColors as well (Material You, coloring based on launcher wallpaper colors), but that would be much more work.

moving-bits commented 1 year ago

I've done a quick test with replacing the base themes (when available). Some first findings (TBC):

image.image.image.image

fm-sys commented 1 year ago

(Even though I'm using dark mode myself, it looks somewhat outdated compared to more recent apps. We could think of introducing a few more colors into c:geo, chosen from a harmonized color palette, to make it look a bit more up to date visually... But that's a different discussion.)

Originally posted by @moving-bits in https://github.com/cgeo/cgeo/issues/14573#issuecomment-1704068109

Material 3 is designed to look quite nice if implemented right. I would like to take a closer look at the coloring as time permits... Maybe in the middle of next week

moving-bits commented 1 year ago

I would like to take a closer look at the coloring as time permits... Maybe in the middle of next week

Highly appreciated. Maybe you can push directly to PR #14574?

fm-sys commented 1 year ago

It's quite disappointing that the Material 3 documentation is so much worse compared to older versions of Material. I spent at least two hours trying to find a Material theme color generator.

Apart from a few guideline pictures, I haven't found a single line of implementation guidelines. The design looks nice, but as a developer, I want to know how I can make my app look like this. What has happened to the Material project?!

https://m3.material.io/theme-builder#/custom

fm-sys commented 1 year ago

I've just pasted our current color accent as primary color and let material calculate all other colors out of it...

Might actually look pretty good.

And the suggested colors aren't too bright, so we might want to replace our current outlined buttons with grafik that style, which would make our UI more colorful while still don't overdo it.

day theme night theme
grafik grafik

For sure, this would change our accent color from orange to brown (at least in light theme). However, this somehow makes sense when thinking about contrast, etc.

day theme night theme
grafik grafik
fm-sys commented 1 year ago

Some early pictures... What do you think in general?

grafik grafik grafik grafik
grafik grafik grafik grafik
eddiemuc commented 1 year ago

Looks great!

fm-sys commented 1 year ago

See PR #14580 for Material3 migration (nightly ready IMHO)

moving-bits commented 1 year ago

Thanks @fm-sys for the work you've put in, looks great in general. Although I'm not sure I like the specific colors, too brownish-rose-like, IMHO - but that's a matter of personal taste -, and c:geo-orange got lost.

Anyway, we should merge the PR rather soon to get this large change into the nightlies without risking too many conflicts, and see what feedback will be coming in. Colors (if we should decide to use some different) and some remaining quirks can be fixed later on.

Which raises the question of upcoming release, especially with having targetSDK 33 in mind. - See https://github.com/cgeo/cgeo/issues/14283#issuecomment-1708941616 for a proposal on this.

fm-sys commented 1 year ago

Although I'm not sure I like the specific colors, too brownish-rose-like, IMHO - but that's a matter of personal taste -, and c:geo-orange got lost.

Yes, changes always take some time getting used to.

As written above, there is a material color palette generator. I've pasted exactly our current color accent, and that's what came out. Honestly, I was pretty surprised as well. However, I can understand why it is recommended that way. Our old color accent was too bright as background color but still had not enough contrast as text color.

Imagine, all those brownish-rose-like buttons would appear in bright orange. That would definitely be too much.

Material3 generally looks more pastel. And (unfortunately?) that's just what happens with orange if you adjust the brightness.

During the last two days, I've worked almost 10 hours with the rose-like version and have to say that I really like it meanwhile. OTOH the brown version still looks strange to me, but it was less than one hour view time. Maybe it'll look good as well after getting used to it.

Anyway, the color palette as well as individual places can easily be adapted later on.

ztNFny commented 1 year ago

splash screen now uses green as background color which doesn't appear to be used elsewhere, that seems a bit strange.

Many apps offer to customize the material color, maybe that's something we should also do. We have sooo many color options, but none for the now main-color. Or at least we could use such an option to experiment a bit to decide on one color - I'm not so convinced of the current palette (but don't have a better one to offer at this point)

fm-sys commented 1 year ago

splash screen now uses green as background color which doesn't appear to be used elsewhere, that seems a bit strange.

This is definitely not intended. But probably it'll make sense to use the official splash screen library instead of ourccurrent self implemented one... Will look into it

MagpieFourtyTwo commented 1 year ago

Stumbled about the new colors (and way smaller button icons) today - and although I appreciate the approach to implement Material3, the current colors are a real pain in the eyes. And apart from e. g. the thrilling text highlight color, it became really hard to distinguish between different text states like e. g. disabled and archived caches. And even the selected topic of the bottom menu is hard to distinguish from the others. While things get even worse once you're walking in direct sunlight. Differences in color are just way too small. Moreover c:geo now looks more like ... hmmm ... like Barbie's bathroom than like an outdoor app ... ;)

TMALSS: I would really appreciate having back functional colors again. I'd even be happy with the c:geo-typical orange, which I admit I never really fell in love with, but it at least worked. And was way less ... barbie-ish. ;)

00 Text highlighted by Barbie

Disabled vs archived (nearly no difference in color): 01 Disabled 02 Archived

Bottom menu: Nearly impossible to see which text is active, esp. in bright sunlight: 03 Bottom menu

Lineflyer commented 1 year ago

BTW: I also think its a bit to brownish and a bit to less of our accent color (in dark mode, did not check light mode yet).

I found, that the wypoint popup and the cache popup look different, IMHO the waypoint popup is "wrong" colored:

image

image

fm-sys commented 1 year ago

Many thanks for all the feedback!

As writen above, I'm not yet convinced with the colors either and will play around with it in the next days.

(Sorry to all nightly users, I hope I didn't overstep the mark. Still I wanted to try it out how nightly users will react. Thanks for your patience!)

fm-sys commented 1 year ago

As discussed in an internal dev meeting, we will prepare a revert for now. We might need to create a new beta version rather quickly cause of other upcoming changes, but also want to take enough time to do Material 3 in a good way. Furthermore we don't want to annoy nightly users for too long.

In parallel I'll work on a better color palette, and would like to ask everyone who participated in that issue to provide as much feedback as possible as soon as new potential colors are available. I'll post screenshots when I'm ready.

@moving-bits have you already started working on the revert? Otherwise I can do this this evening...

ztNFny commented 1 year ago

I have a problem with material3 in general - imho it's a big step back. That said the main issues I see with the current state:

my proposal would be to focus on trying to come up with color scheme(s) first, review them in the next meeting. And only once we have that focus on all those small inconsistencies as those for sure will require a lot of attention to detail = time to tewak.

moving-bits commented 1 year ago

@moving-bits have you already started working on the revert? Otherwise I can do this this evening...

I have been working on it in parallel. I have reverted the four commits related to Material3 and adjusted a background color setting in the new Matrix filter, so that master includes everything except Material3.

Then I created a new branch material3, branched from head of master, and reverted my revert there, so that we have everything including Material3 on branch material3, and are able to merge this back to master later on.

fm-sys commented 1 year ago

we should try to offer multiple schemes. I'd really like a "dark toolbar, light everything else" theme

This is unfortunately not possible (easily). Furthermore I don't know a single app which uses a dark Actionbar in light theme.

In general: I'm against having several different schemes (except light/dark). IMHO the scheme should just be good enough so that everyone can live with it. Requesting "my own personal color scheme" sounds to me like just hide larger problems and making the user responsible to fix a bad default coloring.

Additional question: What do you mean with "toolbar"? c:geos actionbar or the system statusbar?

fm-sys commented 1 year ago

@moving-bits have you already started working on the revert? Otherwise I can do this this evening...

I have been working on it in parallel. [...]

Thank you very much! Sounds perfect!

ztNFny commented 1 year ago

The main idea of material3 is dynamic theming (https://m3.material.io/styles/color/dynamic-color/overview) where the colors follow the users wallpaper. Most material3 apps I know offer custom themes in addition to the dynamic one.

fm-sys commented 1 year ago

The main idea of material3 is dynamic theming where the colors follow the users wallpaper. Most material3 apps I know offer custom themes in addition to the dynamic one.

Maybe I haven't fully understood it yet, but AFAIK this dynamic/custom theming just works when sticking with the defaults (set a single branding color and everything else gets calculated automatically). And you have seen what happens when we just throw in our current accent color.

But maybe I'm wrong with that. Will have to check again.

ztNFny commented 1 year ago

This is unfortunately not possible (easily). Furthermore I don't know a single app which uses a dark Actionbar in light theme.

The current light theme uses a dark action barsignal-2023-09-11-22-38-36-124.jpg

fm-sys commented 1 year ago

I don't know a single app which uses a dark Actionbar in light theme.

The current light theme uses a dark action bar

Except old c:geo of course. The most prominent reason btw why old light theme can be considered ugly. Any other example?!

MagpieFourtyTwo commented 1 year ago

@fm-sys

As discussed in an internal dev meeting, we will prepare a revert for now.

Thx a lot to the whole team - although there are, objectively seen, way more important things than the colors of the app you're working with, I was surprised to recognize that over the weekend even me lost some of the fun I used to have while "working" in and with c:geo. Obviously it's not all about functionality, but colors also do quite a lot to us ... thus I highly appreciate the decision to make a second, more "cautiously" approach. And big thanks, too, from my fellow cachers, some of whom also use the Nightly and were equally "surprised". And even the others noticed that something changed moodwise. [;)]

Furthermore we don't want to annoy nightly users for too long.

Please don't get me wrong: If it's a process (with a good ending), at least I can handle a lot of "annoyance." [;)] Cause in general you all do a really great job. Can't say "thanks" enough - cause with this app you are the ones who make geocaching fun. Therefore patience and feedback should be the least we can (and will) give back, anyway.

I'll post screenshots when I'm ready.

Screenshots are good, of course, but (at least for me) just "better than nothing". They can't create the feeling that comes from using it ... therefore, if you eventually managed to find a palette which is at least close to the "outdated look" [;)] (and even contains contrasts - I really dislike this soft rinsed "modern" coloring) I would prefer to get an installable version and the chance to work with it for a few days ... (to afterwards go back to the "normal" Nightly, of course) ... would this be possible in any way?

fm-sys commented 1 year ago

@MagpieFourtyTwo Thank you so much to such wonderful testers. Your constant and motivating early feedback also drives us to keep going!

I was surprised to recognize that over the weekend even me lost some of the fun I used to have while "working" in and with c:geo.

Well, instead of dark brown, maybe the "barbie mode" would have given you a better mood? Just kidding... Thanks a lot for sharing these observations!

Screenshots are good, of course, but (at least for me) just "better than nothing". They can't create the feeling that comes from using it [...] I would prefer to get an installable version and the chance to work with it for a few days ... (to afterwards go back to the "normal" Nightly, of course) ... would this be possible in any way?

We had such a special nightly version while working on the bottom navigation as well as Storage Access Framework. Switching between that build and regular nightly back and forth is easily possible, as long as the other version is at least from the same day or newer. We'll make everything possible, which helps for testing ;)

@Lineflyer could you set up that old job again for material3 branch? Thanks a lot!

ztNFny commented 1 year ago

Except old c:geo of course. The most prominent reason btw why old light theme can be considered ugly. Any other example?!

I don't consider the current light theme ugly at all. The dark-theme is an absolute no-go for me though. Dark content (cache listings, lists,...) is ugly and unusable to me.

While few apps nowadays use the KitKat-introduced AppCompat with Dark.Actionbar most apps out there use a darker color for actionbar, e.g. the apps primary color, while using white/light grey for bottom navigation and dialogs.

Lomanic commented 1 year ago

Is there really any point following this latest trend in cgeo? Did you have remarks that the current UI looks outdated? I really feel that Material3 with its big rounded corners and wasted space everywhere doesn't fit the cgeo aesthetics (as a utilitarian app).

(Thanks for reverting the nightlies by the way)

Lineflyer commented 1 year ago

@Lineflyer could you set up that old job again for material3 branch? Thanks a lot!

Will take a look and follow up here.

MagpieFourtyTwo commented 1 year ago

@Lomanic To be honest, I've been asking myself the exact same question. But I guess it's more about keeping up with the current look and feel. At some point you just have to make a move to not suddenly look like Atari's character art version of Snake one day, while all the rest is in 8k and 4D. [;)] And, no matter what, it's better to start early than to just miss that point. Cause then it's too late.

Nevertheless, as this material version seems to be really questionable, I would also be more in favor of skipping this one. Even more as most c:geo users I know, primarily want a consistent GUI with as few changes as possible anyway. Cause they are just happy to be able to use at least their (typically small) subset of c:geo's functions, they possibly even have understood - and they don't want to additionally be forced to deal with permanent changes. Thus IMHO, too, consistency should have a higher prio than chasing every fashion trend. One should keep in mind that c:geo is not a beauty or fashion app, but should be functional first and foremost.

Just my 2 Cent.

Lineflyer commented 1 year ago

Job has been configured here

You can now download a nightly build from material3 theme here: https://download.cgeo.org/cgeo-nightly-material.apk (Refreshed at 1am each night).

A change between "normal" nightly and "material" nightly can be done on each upgrade.

I did not install it, so its not tested, that it really runs as expected, but the build log looks normal.

MagpieFourtyTwo commented 1 year ago

A change between "normal" nightly and "material" nightly can be done on each upgrade.

Great! *thumbsup*

What do you think about adding the link to the "Download Nightly Builds" section in https://www.cgeo.org/development ?

@fm-sys Please let us know, once a test-worthy version is available.

fm-sys commented 1 year ago

What do you think about adding the link to the "Download Nightly Builds" section in https://www.cgeo.org/development ?

At least not in such an early state. But we'll keep it in mind.

@fm-sys Please let us know, once a test-worthy version is available

I definitely will. But as we have reverted anyway for now and will have to wait till after the next beta anyway, there is no pressure for me and I have re-priorized my time a bit. Maybe next week...

MagpieFourtyTwo commented 1 year ago

At least not in such an early state.

This of course only makes sense once the first test-worthy version is up and running.

But (...) will have to wait till after the next beta

Hmm, as for me, I don't really wait for material 3, so there must be no hurry, anyway. [;)] Nevertheless, I don't understand why this should depend on betas, as the m3 branch is based on the nightly branch and therefore can be exchanged with the nightlies ... or did I get s/th wrong?

fm-sys commented 1 year ago

Yes, sure. Development can continue right now on that branch, it's just our time schedule we have agreed with as well as other important personal things I'll have to do in parallel apart from cgeo...

Lineflyer commented 1 year ago

BTW: Knowing that the current color scheme has been derived automatically: Isn't there a possibility to apply the former colors to the new scheme (i.e. same colors, just new material3 styled icons) and start from there. The coloring right now just is not c:geo anymore, and I think there is no need to stick to the coloring rules of material3 just for making it look like all other apps with its pastel-coloring.

flexagoon commented 1 year ago

I just installed the nightly build and it uses the default c:geo color scheme instead of my system colors. Are you planning to support Material You dynamic colors as well?

bekuno commented 1 month ago

Our branch Material3 has now been untouched for a year. Do we want to make another/further migration attempt or should we remove the branch? If we decide to end the material3 experiment, we must also remove the CI job c-geo-nightly_material3.

fm-sys commented 1 month ago

Please disable but not remove the ci job, as it is used from time to time for test larger refactorings.