#[derive(Clone, Debug, Copy, PartialEq, Eq)]
pub enum SlideLayout {
CenteredTitle,
TitleAndContent,
TwoColumn,
SectionHeader,
Blank,
TitleOnly,
TitleAndBigContent,
}
impl SlideLayout {
pub fn layout_number(&self) -> usize {
match self {
SlideLayout::CenteredTitle => 1,
SlideLayout::TitleAndContent => 2,
SlideLayout::TwoColumn => 3,
SlideLayout::SectionHeader => 4,
SlideLayout::Blank => 5,
SlideLayout::TitleOnly => 6,
SlideLayout::TitleAndBigContent => 7,
}
}
pub fn as_str(&self) -> &'static str {
match self {
SlideLayout::TitleOnly => "titleOnly",
SlideLayout::TitleAndContent => "titleAndContent",
SlideLayout::TitleAndBigContent => "titleAndBigContent",
SlideLayout::Blank => "blank",
SlideLayout::CenteredTitle => "centeredTitle",
SlideLayout::TwoColumn => "twoColumn",
SlideLayout::SectionHeader => "sectionHeader",
}
}
}