����JFIF���������
__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
/*
* << Haru Free PDF Library 2.0.5 >> -- OutlineDemo.cs
*
* Copyright (c) 1999-2006 Takeshi Kanno <takeshi_kanno@est.hi-ho.ne.jp>
*
* Permission to use, copy, modify, distribute and sell this software
* and its documentation for any purpose is hereby granted without fee,
* provided that the above copyright notice appear in all copies and
* that both that copyright notice and this permission notice appear
* in supporting documentation.
* It is provided "as is" without express or implied warranty.
*
*/
using System;
using System.IO;
using HPdf;
public class OutlineDemo {
private static void PrintPage(HPdfPage page, int page_num) {
page.SetWidth(800);
page.SetHeight(800);
page.BeginText();
page.MoveTextPos(30, 740);
string buf = "Page:" + page_num;
page.ShowText(buf);
page.EndText();
}
public static void Main() {
Console.WriteLine("libhpdf-" + HPdfDoc.HPdfGetVersion());
try {
HPdfDoc pdf = new HPdfDoc();
pdf.SetCompressionMode(HPdfDoc.HPDF_COMP_ALL);
/* create default-font */
HPdfFont font = pdf.GetFont("Helvetica", null);
pdf.SetPageMode(HPdfPageMode.HPDF_PAGE_MODE_USE_OUTLINE);
/* add a new page object. */
/* Add 3 pages to the document. */
HPdfPage page0 = pdf.AddPage();
page0.SetFontAndSize (font, 30);
PrintPage(page0, 1);
HPdfPage page1 = pdf.AddPage();
page1.SetFontAndSize(font, 30);
PrintPage(page1, 2);
HPdfPage page2 = pdf.AddPage();
page2.SetFontAndSize(font, 30);
PrintPage(page2, 3);
/* create outline root. */
HPdfOutline root = pdf.CreateOutline(null, "OutlineRoot", null);
root.SetOpened (true);
HPdfOutline outline0 = pdf.CreateOutline(root, "page1", null);
HPdfOutline outline1 = pdf.CreateOutline(root, "page2", null);
/* create outline with test which is ISO8859-2 encoding */
HPdfOutline outline2 = pdf.CreateOutline(root, "ISO8859-2 text �������",
pdf.GetEncoder("ISO8859-2"));
/* create destination objects on each pages
* and link it to outline items.
*/
HPdfDestination dst = page0.CreateDestination();
dst.SetXYZ(0, page0.GetHeight(), 1);
outline0.SetDestination(dst);
dst = page1.CreateDestination();
dst.SetXYZ(0, page1.GetHeight(), 1);
outline1.SetDestination(dst);
dst = page2.CreateDestination();
dst.SetXYZ(0, page2.GetHeight(), 1);
outline2.SetDestination(dst);
/* save the document to a file */
pdf.SaveToFile("OutlineDemo.pdf");
} catch (Exception e) {
Console.Error.WriteLine(e.Message);
}
}
}
| Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| Encryption.cs | File | 1.74 KB | 0644 |
|
| FontDemo.cs | File | 2.99 KB | 0644 |
|
| ImageDemo.cs | File | 5.69 KB | 0644 |
|
| JPFontDemo.cs | File | 5.53 KB | 0644 |
|
| LineDemo.cs | File | 9.57 KB | 0644 |
|
| OutlineDemo.cs | File | 2.99 KB | 0644 |
|
| Permission.cs | File | 1.92 KB | 0644 |
|
| RawImageDemo.cs | File | 3.6 KB | 0644 |
|
| SlideShowDemo.cs | File | 6.67 KB | 0644 |
|
| TextDemo.cs | File | 10.35 KB | 0644 |
|