Enumerations

Enumerations — Aspose.Note FOSS for Python API Reference

ImageRenderOptions

Tutte le enumerazioni sono esposte direttamente da aspose.note pacchetto:

from aspose.note import SaveFormat, FileFormat, HorizontalAlignment, NodeType

Tutti i membri dell’enum sono standard Python enum.Enum istanze.


SaveFormat

ImageRenderOptions: from aspose.note import SaveFormat

Indica il formato di output passato a Document.Save().

ImageRenderOptionsValore stringaStato in v26.3.1
SaveFormat.Pdf"pdf"Implementato — richiede pip install "aspose-note[pdf]"
SaveFormat.One"one"Non implementato — genera UnsupportedSaveFormatException

ImageRenderOptions

from aspose.note import Document, SaveFormat

doc = Document("MyNotes.one")

##Save to PDF (implemented)
doc.Save("output.pdf", SaveFormat.Pdf)
from aspose.note import SaveFormat

##Iterate all members
for fmt in SaveFormat:
    print(fmt.name, fmt.value)

FileFormat

ImageRenderOptions: from aspose.note import FileFormat

Rappresenta la versione del formato file OneNote. Usato da Document.FileFormat.

ImageRenderOptionsValore stringaImageRenderOptions
FileFormat.OneNote2010"onenote2010"Formato sezione standard OneNote 2010 / OneNote per Windows 10
FileFormat.OneNoteOnline"onenoteonline"Formato OneNote Online
FileFormat.OneNote2007"onenote2007"Formato legacy OneNote 2007

Document.FileFormat nota: Il Document.FileFormat la proprietà fornisce un’indicazione di massima della versione del formato file OneNote.

ImageRenderOptions

from aspose.note import Document, FileFormat

doc = Document("MyNotes.one")
if doc.FileFormat == FileFormat.OneNote2010:
    print("OneNote 2010 format")

HorizontalAlignment

ImageRenderOptions: from aspose.note import HorizontalAlignment

Allineamento orizzontale del testo o dell’oggetto. Dichiarato per compatibilità API; attualmente non applicato a nessun nodo in v26.3.1.

ImageRenderOptionsValore stringa
HorizontalAlignment.Left"left"
HorizontalAlignment.Center"center"
HorizontalAlignment.Right"right"

ImageRenderOptions

from aspose.note import HorizontalAlignment

alignment = HorizontalAlignment.Left
print(alignment.value)  # "left"

NodeType

ImageRenderOptions: from aspose.note import NodeType

Nomi simbolici per i tipi di nodo nel modello a oggetti del documento. Dichiarati per compatibilità API; non usati dall’API pubblica per l’identificazione dei nodi in v26.3.1 (usa isinstance controlli o GetChildNodes(Type) invece).

ImageRenderOptionsValore stringaClasse corrispondente
NodeType.Document"document"Document
NodeType.Page"page"Page
NodeType.Outline"outline"Outline
NodeType.OutlineElement"outline_element"OutlineElement
NodeType.RichText"rich_text"RichText
NodeType.Image"image"Image
NodeType.Table"table"Table
NodeType.AttachedFile"attached_file"AttachedFile

ImageRenderOptions

from aspose.note import NodeType

##Inspect all members
for nt in NodeType:
    print(nt.name, "->", nt.value)
from aspose.note import NodeType

##Compare by value string
node_type_value = "rich_text"
if node_type_value == NodeType.RichText.value:
    print("This is a RichText node type")

Identificazione nodo preferita: In pratica, usa isinstance(node, RichText) o page.GetChildNodes(RichText) piuttosto che NodeType confronti.


Vedi anche

 Italiano