mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-06 11:46:41 +01:00
add no-github badge
This commit is contained in:
parent
38e8cfc214
commit
2b78339e61
4 changed files with 19 additions and 11 deletions
|
|
@ -1,5 +1,7 @@
|
||||||
# tek
|
# tek
|
||||||
|
|
||||||
|
[](https://nogithub.codeberg.page)
|
||||||
|
|
||||||
a music making program for your terminal
|
a music making program for your terminal
|
||||||
|
|
||||||
## project status
|
## project status
|
||||||
|
|
|
||||||
|
|
@ -20,14 +20,14 @@ impl<E: Engine, S, C: Command<S>> MenuBar<E, S, C> {
|
||||||
pub struct Menu<E: Engine, S, C: Command<S>> {
|
pub struct Menu<E: Engine, S, C: Command<S>> {
|
||||||
pub title: String,
|
pub title: String,
|
||||||
pub items: Vec<MenuItem<E, S, C>>,
|
pub items: Vec<MenuItem<E, S, C>>,
|
||||||
pub index: usize,
|
pub index: Option<usize>,
|
||||||
}
|
}
|
||||||
impl<E: Engine, S, C: Command<S>> Menu<E, S, C> {
|
impl<E: Engine, S, C: Command<S>> Menu<E, S, C> {
|
||||||
pub fn new (title: impl AsRef<str>) -> Self {
|
pub fn new (title: impl AsRef<str>) -> Self {
|
||||||
Self {
|
Self {
|
||||||
title: title.as_ref().to_string(),
|
title: title.as_ref().to_string(),
|
||||||
items: vec![],
|
items: vec![],
|
||||||
index: 0
|
index: None,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pub fn add (mut self, item: MenuItem<E, S, C>) -> Self {
|
pub fn add (mut self, item: MenuItem<E, S, C>) -> Self {
|
||||||
|
|
|
||||||
|
|
@ -131,7 +131,7 @@ impl<E: Engine> Arranger<E> {
|
||||||
jack: jack.clone(),
|
jack: jack.clone(),
|
||||||
focus_cursor: (0, 1),
|
focus_cursor: (0, 1),
|
||||||
phrases_split: 20,
|
phrases_split: 20,
|
||||||
arrangement_split: 21,
|
arrangement_split: 15,
|
||||||
editor: PhraseEditor::new(),
|
editor: PhraseEditor::new(),
|
||||||
status: ArrangerStatusBar::ArrangementClip,
|
status: ArrangerStatusBar::ArrangementClip,
|
||||||
transport: transport.clone(),
|
transport: transport.clone(),
|
||||||
|
|
|
||||||
|
|
@ -5,17 +5,23 @@ impl Content for Arranger<Tui> {
|
||||||
fn content (&self) -> impl Widget<Engine = Tui> {
|
fn content (&self) -> impl Widget<Engine = Tui> {
|
||||||
Split::down(
|
Split::down(
|
||||||
1,
|
1,
|
||||||
widget(&self.transport),
|
row!(menu in self.menu.menus.iter() => {
|
||||||
|
row!(" ", menu.title.as_str(), " ")
|
||||||
|
}),
|
||||||
Split::up(
|
Split::up(
|
||||||
1,
|
1,
|
||||||
widget(&self.status),
|
widget(&self.status),
|
||||||
Split::down(
|
Split::up(
|
||||||
self.arrangement_split,
|
1,
|
||||||
widget(&self.arrangement),
|
widget(&self.transport),
|
||||||
Split::right(
|
Split::down(
|
||||||
self.phrases_split,
|
self.arrangement_split,
|
||||||
self.phrases.clone(),
|
widget(&self.arrangement),
|
||||||
widget(&self.editor),
|
Split::right(
|
||||||
|
self.phrases_split,
|
||||||
|
self.phrases.clone(),
|
||||||
|
widget(&self.editor),
|
||||||
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue