src/nimiSlides

Search:
Group by:
Source   Edit  

Types

Corner = enum
  UpperLeft, UpperRight, LowerLeft, LowerRight
Source   Edit  
FragmentAnimation = enum
  fadeIn = "fade-in", fadeOut = "fade-out", fadeUp = "fade-up",
  fadeDown = "fade-down", fadeLeft = "fade-left", fadeRight = "fade-right",
  fadeInThenOut = "fade-in-then-out",
  fadeInThenSemiOut = "fade-in-then-semi-out", grows = "grow",
  semiFadeOut = "semi-fade-out", shrinks = "shrink", strike = "strike",
  highlightRed = "highlight-red", highlightGreen = "highlight-green",
  highlightBlue = "highlight-blue",
  highlightCurrentRed = "highlight-current-red",
  highlightCurrentGreen = "highlight-current-green",
  highlightCurrentBlue = "highlight-current-blue"
Source   Edit  
NimiSlidesConfig = object
  localReveal*: string
Source   Edit  
SlideOptions = object
  autoAnimate*: bool
  colorBackground*: string
  imageBackground*: string
  videoBackground*: string
  iframeBackground*: string
  iframeInteractive*: bool
  gradientBackground*: string
Source   Edit  
SlidesTheme = enum
  Black, Beige, Blood, Dracula, League, Moon, Night, Serif, Simple, Sky,
  Solarized, White
Source   Edit  

Consts

reveal_version = "5.0.4"
Source   Edit  

Procs

proc addStyle(doc: NbDoc; style: string) {....raises: [KeyError, Exception],
    tags: [RootEffect], forbids: [].}
Source   Edit  
proc revealTheme(doc: var NbDoc) {....raises: [KeyError, Exception], tags: [
    ReadIOEffect, RootEffect, WriteIOEffect], forbids: [].}
Source   Edit  
proc slideOptions(autoAnimate = false; iframeInteractive = true;
    colorBackground, imageBackground, videoBackground, iframeBackground,
    gradientBackground: string = ""): SlideOptions {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
proc slideOptionsToAttributes(options: SlideOptions): string {.
    ...raises: [ValueError], tags: [], forbids: [].}
Source   Edit  
proc useLocalReveal(nb: var NbDoc; path: string) {....raises: [OSError], tags: [],
    forbids: [].}
Source   Edit  

Templates

template adaptiveColumns(body: untyped)
Source   Edit  
template adaptiveColumns(columnGap: float; body: untyped)
Source   Edit  
template align(text: string; body: untyped)
Source   Edit  
template animateCode(lines: string; body: untyped)
Source   Edit  
template animateCode(lines: varargs[set[range[0 .. 65535]], toSet];
                     body: untyped)
Shows code and its output just like nbCode, but highlights different lines of the code in the order specified in lines. lines: Specify which lines to highlight and in which order. The lines can be specified using either:
  • An int (highlight single line)
  • A slice x..y (highlight a range of consequative lines)
  • A set {x, y..z} (highlight any combination of lines)

Ex:

animateCode(1, 2..3, {4, 6}): body
This will first highlight line 1, then lines 2 and 3, and lastly line 4 and 6.

Source   Edit  
template bigText(text: string)
Source   Edit  
template column(bodyInner: untyped)
column should always be used inside a columns block Source   Edit  
template columns(body: untyped)
Source   Edit  
template columns(columnGap: float; body: untyped)
Source   Edit  
template cornerImage(image: string; corner: Corner; size: int = 100;
                     animate = true; verticalPadding: int = 2;
                     horizontalPadding: int = 1)
Source   Edit  
template disableVerticalCentering()
Source   Edit  
template fadeInNext(body: untyped)
Source   Edit  
template fitImage(src: string)
Source   Edit  
template fragment(animation: FragmentAnimation; body: untyped)
fragment(animation) is shorthand for fragment(@animation) Source   Edit  
template fragment(animations: varargs[seq[FragmentAnimation]] = @[@[fadeIn]];
                  body: untyped): untyped
Creates a fragment of the content of body. Nesting works. animations: each seq of the varargs are animations that are to be applied at the same time. The first seq's animations are applied on the first button click, and the second seq's animations on the second click etc. Example: fragment(@[fadeIn, highlightBlue], @[shrinks, semiFadeOut]): block will at the first click of a button fadeIn and highlightBlue the content of the block. At the second click the same content will shrink and semiFadeOut. This code is also equivilent with fragment(@[fadeIn, highlightBlue]): fragment(@[shrinks, semiFadeOut]): block. Source   Edit  
template fragment(body: untyped)
Source   Edit  
template fragmentCore(animations: openArray[seq[FragmentAnimation]];
                      endAnimations: openArray[seq[FragmentAnimation]];
                      indexOffset: untyped; incrementCounter: untyped;
                      body: untyped)
Creates a fragment of the content of body. Nesting works. animations: each seq in animations are animations that are to be applied at the same time. The first seq's animations are applied on the first button click, and the second seq's animations on the second click etc. endAnimations: animations that should be applied AT THE END of block. Example: fragment(@[@[fadeIn, highlightBlue], @[shrinks, semiFadeOut]]): block will at the first click of a button fadeIn and highlightBlue the content of the block. At the second click the same content will shrink and semiFadeOut. This code is also equivilent with fragment(@[@[fadeIn, highlightBlue]]): fragment(@[@[shrinks, semiFadeOut]]): block. fragment(@[@[fadeIn]], @[@[fadeOut]]): block will first fadeIn the entire block and perform eventual animations in nested fragments. Once all of those are finished, it will run fadeOut on the entire block and its subfragments. Source   Edit  
template fragmentCore(animations: openArray[seq[FragmentAnimation]];
                      endAnimations: openArray[seq[FragmentAnimation]];
                      body: untyped)
Source   Edit  
template fragmentEnd(endAnimation: FragmentAnimation; body: untyped)
Source   Edit  
template fragmentEnd(endAnimation: varargs[seq[FragmentAnimation]];
                     body: untyped)
Source   Edit  
template fragmentFadeIn(animation: FragmentAnimation; body: untyped)
Source   Edit  
template fragmentFadeIn(animation: varargs[seq[FragmentAnimation]];
                        body: untyped)
Source   Edit  
template fragmentFadeIn(body: untyped)
Source   Edit  
template fragmentList(list: seq[string]; animation: FragmentAnimation)
Source   Edit  
template fragmentList(list: seq[string];
                      animation: varargs[seq[FragmentAnimation]])
Source   Edit  
template fragmentNext(an: FragmentAnimation; body: untyped)
Source   Edit  
template fragmentNext(an: seq[FragmentAnimation]; body: untyped)
Source   Edit  
template fragmentThen(an1, an2: FragmentAnimation; body: untyped)
Source   Edit  
template fragmentThen(an1, an2: seq[FragmentAnimation]; body: untyped)
Source   Edit  
template listItem(animation: FragmentAnimation; body: untyped)
Source   Edit  
template listItem(animation: seq[FragmentAnimation]; body: untyped)
Source   Edit  
template listItem(body: untyped)
Source   Edit  
template newAnimateCodeBlock(cmd: untyped; impl: untyped)
Source   Edit  
template orderedList(body: untyped)
Source   Edit  
template setSlidesTheme(theme: SlidesTheme)
Source   Edit  
template showSlideNumber()
Source   Edit  
template slide(body: untyped)
Source   Edit  
template slide(options: untyped; body: untyped): untyped
Source   Edit  
template slideAutoAnimate(body: untyped)
Source   Edit  
template speakerNote(text: string)
Source   Edit  
template typewriter(textMessage: string; typeSpeed = 50; alignment = "center")
Source   Edit  
template unorderedList(body: untyped)
Source   Edit  
template useScrollView()
Source   Edit  
template useScrollWheel()
Enable using the scroll-wheel to step forward in slides. Source   Edit