Planet PDF Forum Archive

Planet PDF ForumWowsers! This is page is old, head to the LIVE Planet PDF Forum. It features more than 10 conferences, covering everything from beginner to in-depth developer and pre-press discussions. If you wish to continue... one & two archive covers 1999-2011 (160,000 pages).


New Forum | Previous | Next | (P-PDF) Developers


Topic: Re: Acrobat Core API Question
Conf: (P-PDF) Developers, Msg: 56235
From: teryk
Date: 5/29/2002 05:18 PM

It's fun to pass down a little bit of history. COS stands for Carousel
Object Store. Carousel was the initial code name for Acrobat. You will also
see it in the Type and Creator fields for PDF files on the Macintosh. Some
people also claim it stands for COS Object Store, but that discussion could
go on forever.

If you read the PDF file specification version 1.3, section 3.2 discusses
objects. Each of these basic types, as well as composite objects, have an
in memory representation referred to as a CosObject. The Cos level of the
API is considered the lowest level of the API. Working at that level
provides the least amount of abstraction from the PDF file format and the
least amount of protection to ensure that you create valid PDF.

Using annotions as an example, if you create a PDAnnot object and add it to
the page using PDPageAddNewAnnot(), the method knows that annot objects
must be added to the annots array for that page and does it for you. The
Cos level provides no such assistance. You could call CosObjDestroy() on
the CosObject returned from PDAnnotGetCosObj(). The annot object would be
destroyed but the reference in the annots array would not be removed. The
resulting PDF would be invalid and raise an error when trying to draw that
page.

In general, it is best to use the higher level abstractions in the API
(PDAnnot, PDDoc, etc) where they are available and use the Cos level only
when necessary. When using CosObjects to create form fields, keep the PDF
Specification close at hand and pay careful attention to direct and
indirect object types as well as inheritance of form field attributes or
risk creating invalid or inefficient PDF.

-Teryk



At 11:22 AM 7/18/01 -0400, you wrote:
>From: "Ariel"
>
>--- Planet PDF Forum | http://forum.planetpdf.com ----
>
>Thank you, I thought so, but was not sure.
>By the way what does COS mean?
>What is the difference between an annot object
>and a cos object?
>thanks again
>
>On 7/18/2001 11:11:05 AM, mgavin wrote:
> >
> >>Hi,
> >> I need a little help in figuring out which of the
> >>API objects refer to PDF Form fields. My C/C++ is
> >>rusty. The Acrobat Forms API reference mentions a PDField object,
> >>and goes on to say that the Core API reference has details. I can't
> >>seem to find any
> >>instance of PDField in the core doc.
> >>I'm simply trying to create a pdf form field,
> >>not enumerate it (ala FormDemo.cpp).
> >>
> >>Any suggestions?
> >>
> >>thanks in advance
> >>-Ariel
> >>ariel.fournier@gs.com
> >
> >Ariel,
> >A form field is a type of
> >annotation (widget). As such
> >you can
> >create a new form field on a
> >PDPage using
> >PDPageCreateAnnot. You
> >then need to create the
> >various CosObjects needed by a
> >form field and
> >add them to the PDAnnot using
> >CosDictPut.
> >
> >Regards,
> >--
> >
> >Mark Gavin
> >Chief Technology Officer
> >Appligent, Inc. (formerly
> >Digital Applications, Inc.)
> >60 South Lansdowne Avenue
> >Lansdowne, PA 19050
> >(610) 284-4006
> >http://www.appligent.com
>
>
>
>
>
>------- Planet PDF Store's Top 10 List for May ---------
>
> ARTS Split and Merge - Stamp PDF - Jaws PDF Creator
> Gemini - Amyuni PDF Converter - Crackerjack - BCL Drake
> iCopy - ARTS Import - Mapsoft Impress Stamper
>
> Find out why these were the best-selling products last
> month. Free demos of each at the Planet PDF Store!
> http://www.pdfstore.com/
>
>---- Powered by foxitsoftware.com & www.PlanetPDF.com ----


PDF In-Depth Free Product Trials Ubiquitous PDF

Debenu Aerialist

The ultimate plug-in for Adobe Acrobat. Advanced splitting, merging, stamping, bookmarking, and link...

Download free demo

Debenu PDF Tools Pro

It's simple to use and will let you preview and edit PDF files, it's a Windows application that makes...

Download free demo

Back to the past, 15 years ago! Open Publish 2002

Looking back to 2002, it's amazing how much of the prediction became a reality. Take a read and see what you think!

September 14, 2017
Platinum Sponsor





Search Planet PDF
more searching options...
Planet PDF Newsletter
Most Popular Articles
Featured Product

Debenu PDF Aerialist

The ultimate plug-in for Adobe Acrobat. Advanced splitting, merging, stamping, bookmarking, and link control. Take Acrobat to the next level.

Features

Adding a PDF Stamp Comment

OK, so you want to stamp your document. Maybe you need to give reviewers some advice about the document's status or sensitivity. This tip from author Ted Padova demonstrates how to add stamps with the Stamp Tool along with related comments.