Example #1
0
 public override Bookshelf.Book.Page Serialize()
 {
     Bookshelf.Book.Page page = new Bookshelf.Book.Page
     {
         Type    = Bookshelf.Book.PageType.Text,
         Content = JsonConvert.ToString(new[] { this.Title, this.Subtitle, this.Introduction })
     };
     return(page);
 }
Example #2
0
 public override Bookshelf.Book.Page Serialize()
 {
     Bookshelf.Book.Page page = new Bookshelf.Book.Page
     {
         Type    = Bookshelf.Book.PageType.Text,
         Content = this.Text
     };
     return(page);
 }
Example #3
0
        public override Bookshelf.Book.Page Serialize()
        {
            using (FileStream stream = File.Create(this.FilePath))
                this.Image.SaveAsPng(stream, 150, 245);

            Bookshelf.Book.Page page = new Bookshelf.Book.Page
            {
                Type    = Bookshelf.Book.PageType.Image,
                Content = this.Guid
            };
            return(page);
        }