mirror of
https://github.com/mikedilger/gossip.git
synced 2024-09-19 19:46:50 +00:00
Logarithmic indent, so deep indents don't go too far to the right
This commit is contained in:
parent
3839426b8a
commit
46281ca6e6
@ -134,10 +134,10 @@ fn render_post(
|
|||||||
ui.horizontal(|ui| {
|
ui.horizontal(|ui| {
|
||||||
// Indents first (if threaded)
|
// Indents first (if threaded)
|
||||||
if app.settings.view_threaded {
|
if app.settings.view_threaded {
|
||||||
for _ in 0..indent {
|
let space = 16.0 * (10.0 - (100.0 / (indent as f32 + 10.0)));
|
||||||
ui.add_space(8.0);
|
ui.add_space(space);
|
||||||
|
if indent > 0 {
|
||||||
ui.separator();
|
ui.separator();
|
||||||
ui.add_space(8.0);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user