Specifying document attributes

DjVu products provide several unique document attributes that you can specify using either <embed> or <object> tags, or CGI-style arguments.

Using <embed> or <object> tags

You can specify attributes using the following flags in the <embed> or <object> tags. All flags and their values are case-insensitive and can be specified as either yes or no, or true or false.

Allows any of the flags described here to be assigned in any valid combination. When you use multiple attributes, enclose them in quotation marks and separate them with spaces.
For example: flags="menu=false frame=true logo=yes zoom=width mode=color toolbar=top,auto-print"

Disables or enables caching of fully decoded pages of a DjVu document.
Disables or enables the gray border that frames DjVu documents.
Creates a rectangular highlighted area with given coordinates and color. The parameters are defined as follows:
  • x is the X coordinate of the lower-left corner of the highlighted rectangle in the document's coordinate system.
  • y is the Y coordinate of the lower-left corner of the highlighted rectangle in the document's coordinate system.
  • w is the width of the highlighted rectangle.
  • h is the height of the highlighted rectangle.
  • c is the highlighting color in RRGGBB format. A special value of FF000000 indicates to use XOR highlighting. The color may be omitted, in which case XOR highlighting will be assumed.

For example: "highlight=10,10,300,400,FF00FF"
Disables or enables the use of keyboard shortcuts.
Disables or enables hyperlinks.
Disables or enables the DjVu logo.
Disables or enables the pop-up menu.
Sets the initial display mode as Color, Black and White, Foreground, or Background.
Displays the specified page, which can be any valid page ID in the DjVu document referred by the <embed> tag.
Disables the toolbar, pop-up menu, and keyboard shortcuts and sets the default zoom level to Fit Page. If the parameter "passive" is set, then the above items are disabled.
Disables or enables the scrollbar.
Disables or enables scrollbars and panning. By default, these are enabled.
Specifies where thumbnails appear in the browser window. By default, thumnails appear on the left.
Disables or enables thumbnails, which are disabled by default. (The user can enable thumbnails by choosing Show Thumbnails from the pop-up menu.)
NOTE This tag is supported only in Windows.
Sets the initial zoom level as a percentage, One to One, Fit Width, Fit Page, or Stretch.
"toolbar=[bar_flag,bar_flag,...]+ [button_flag,button_flag,...]" or "toolbar=[bar_flag,bar_flag,...]- [button_flag,button_flag,...]"
Disables or enables the toolbar and sets toolbar conditions. (The user can also enable the toolbar in the Preferences dialog box, if the pop-up menu is enabled.)
To set the toolbar and enable/disable buttons, the following options apply:

bar_flag is one of the following:


button_flag is one of fore_button,back_button,color_button,bw_button,

button_flag is one of the following:




+ means that only the buttons contained within the brackets will be displayed.
- means that the entire toolbar will be displayed except for the specified buttons.
For example, "toolbar=[auto,top]-[rotate,print,save]" will display the entire toolbar on the top of the viewing window with autohide enabled, but without the Rotate, Print and Save buttons.
"toolbar=[auto,top]+[rotate,print,save]" will display the toolbar on the top of the viewing window with autohide enabled and only with the Rotate, Print and Save buttons.

CGI-style arguments

CGI-style arguments use the same flag names and values listed above but specify them differently. To specify a CGI-style argument, append it to the document's URL after the "?" sign, separating flags with "&" signs. CGI-style arguments can also be used inside an html page.

To separate the DjVu arguments from other CGI-style arguments, precede the set of DjVu arguments with the string "djvuopts&".

For example, the following argument disables the pop-up menu and toolbar:


Note that CGI-style arguments are supported only for Web-served documents. CGI-style arguments for local file URLs ("file://...") are not supported.

LizardTech Web page