Code Monkey home page Code Monkey logo

Comments (4)

joshka avatar joshka commented on June 24, 2024

fn title<T: Into>(self, title: T, position: Position) -> Self;

<pre-coffee-josh>
This change would be a "break the world" type change, so it is very likely not the right approach. The underlying idea is sound however. Likely title_at or something similar would work.

from ratatui.

joshka avatar joshka commented on June 24, 2024

<post-coffee-josh>
So the idea with removing block::Title is that Line already has an indication of Left/Center/Right as part of it. For the block titles it doesn't seem like there's any possible use of this field other than positioning. Which leaves the position really only needing top / bottom. What's your thoughts on this?

from ratatui.

LucasPickering avatar LucasPickering commented on June 24, 2024

You know, it never occurred to me to use the alignment field for this. The functionality I want is already possible, and would continue to work with the other proposal. I'm going to close this. Thanks!

from ratatui.

joshka avatar joshka commented on June 24, 2024

The alignment field on title also does the same thing. The overlap in having a Title that contains a Line which both have alignment is where the removal proposal comes from.

from ratatui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.