Open uandere opened 1 year ago
@Kezii @TDHolmes what do you guys think about this?
This was discussed on #14 , how are you handling drawile-rs
& colored
? Those are std
reliant dependencies aren't they?
This was discussed on #14 , how are you handling
drawile-rs
&colored
? Those arestd
reliant dependencies aren't they?
Hi, @TDHolmes! I separated std and no_std functionality by providing new drawille-nostd
crate. Now when adding textplots
to Cargo.toml with default features (std
feature enabled, no changes required), we're using drawille
and colored
. Otherwise, when default-features = false
is specified, we're swithing to the functionality of the drawille-nostd
crate.
What do you think about that?
Sweet! Sounds good
On Sat, Oct 7, 2023 at 6:01 AM Nazar Demchuk @.***> wrote:
This was discussed on #14 https://github.com/loony-bean/textplots-rs/issues/14 , how are you handling drawile-rs & colored? Those are std reliant dependencies aren't they?
Hi, @TDHolmes https://github.com/TDHolmes! I separated std and no_std functionality by providing new drawille-nostd crate. Now when adding textplots to Cargo.toml with default features (std feature enabled, no changes required), we're using drawille and colored. Otherwise, when default-features = false is specified, we're swithing to the functionality of the drawille-nostd crate.
What do you think about that?
— Reply to this email directly, view it on GitHub https://github.com/loony-bean/textplots-rs/pull/50#issuecomment-1751707071, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC5YNWR7TYKSJFAUN4EOKGLX6FHBVAVCNFSM6AAAAAA42LVWSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJRG4YDOMBXGE . You are receiving this because you were mentioned.Message ID: @.***>
Sweet! Sounds good
Thanks! Planning to test this out next week on stm32f4 =)
This pull request adds
no_std
functionality to the library. This allows for embedded development usingtextplots
, although testing is needed to confirm this possibility.This is done by introducing new drawille-nostd crate, which does not rely on standard library features. Now, when adding
textplots
toCargo.toml
dependencies withdefault-features = false
, it will usedrawille-nostd
crate with reduced functionality (no color support):By default,
std
feature is enabled, so you can also use all library's functionality like before, without any changes.