Foxit PDF SDK

Instance Methods | List of all members
FSOptimizerSettings Class Reference
Inheritance diagram for FSOptimizerSettings:

## Instance Methods
(id) | - init
| Constructor. More...
(id) | - initWithOther:
| Constructor, with another optimizer settings object. More...
(BOOL) | - isEmpty
| Check whether current object is empty or not. More...
(void) | - setCleanUpOptions:
| Set optimization related options for cleaning up. More...
(void) | - setColorGrayImageSettings:
(void) | - setColorImageSettings:
| Set optimization related settings for color image. More...
(void) | - setDiscardObjectsOptions:
| Set optimization related options for discarding objects. More...
(void) | - setDiscardUserDataOptions:
| Set optimization related options for discarding user data. More...
(void) | - setGrayscaleImageSettings:
| Set optimization related settings for grayscale image. More...
(void) | - setMonoImageSettings:
| Set optimization related settings for monochrome image. More...
(void) | - setOptimizerOptions:
| Set options to decide which kind of optimizer setting will be used for optimizing PDF document. More...
(void) | - setTransparencyMode:
| Set optimization related options for doing transparency. More...
(void) | - setUnembeddedFontSettings:
| Set optimization related settings for unembedding fonts. More...

## Detailed Description

This class represents settings for optimizing a PDF document. It would be used in class FSOptimizer .

See also
  FSOptimizer

## Method Documentation

## ◆ init()

- (id) init |  |  |

Constructor.

This constructor is to construct a optimizer settings object with default setting options. User can also call "set" methods in this class to change setting options. Please refer to comment in other settings class (which can be set to current object) for more details about what default setting options are.

## ◆ initWithOther:()

- (id) initWithOther: |  | (FSOptimizerSettings*) | other |

Constructor, with another optimizer settings object.

Parameters

  [in] | other | Another optimizer settings object.

## ◆ isEmpty()

- (BOOL) isEmpty |  |  |

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
  YES means current object is empty, while NO means not.

## ◆ setCleanUpOptions:()

- (void) setCleanUpOptions: |  | (unsigned int) | clean_up_options |

Set optimization related options for cleaning up.

For a newly constructed object, if this function is not called to set any clean-up options, that means not to do clean-up optimization. Clean-up options set by this function are useful only when option value FSOptimizerSettingsOptimizerCleanUp is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | clean_up_options | Optimization related options for cleaning up. 0 means not to do clean-up optimization. Please refer to values starting from FSOptimizerSettingsCleanUpUseFlateForNonEncodedStream and this can be one or a combination of these values.

Returns
  None.

## ◆ setColorGrayImageSettings:()

- (void) setColorGrayImageSettings: |  | (FSImageSettings*) | settings |

Deprecated:
  Current function has been deprecated since Foxit PDF SDK 10.0. This function will not have any effect on FSOptimizerSettings any more. For setting color image, please call function FSOptimizerSettings::setColorImageSettings:. Please refer to SetColorImageSettings related function in FSOptimizerSettings for more details. For setting grayscale image, please call function FSOptimizerSettings::setGrayscaleImageSettings:. Please refer to SetGrayscaleImageSettings related function in FSOptimizerSettings for more details.

For a newly constructed object, if this function is not called to set any color/gray image settings, that means to use default color/gray image settings. Please refer to comment in class FSImageSettings for default values.
ImageSettings set by this function is useful only when option value FSOptimizerSettingsOptimizerCompressImages is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | settings | Optimization related settings for color and grayscale images.

Returns
  None.

## ◆ setColorImageSettings:()

- (void) setColorImageSettings: |  | (FSImageSettings*) | settings |

Set optimization related settings for color image.

For a newly constructed object, if this function is not called to set any color image settings, that means to use default color image settings. Please refer to comment in class FSImageSettings for default values.
ImageSettings set by this function is useful only when option value FSOptimizerSettingsOptimizerCompressImages is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | settings | Optimization related settings for color images.

Returns
  None.

## ◆ setDiscardObjectsOptions:()

- (void) setDiscardObjectsOptions: |  | (unsigned int) | discard_objects_options |

Set optimization related options for discarding objects.

For a newly constructed object, if this function is not called to set any discard-objects options, that means not to do discard-objects optimization. Discard-objects options set by this function are useful only when option value FSOptimizerSettingsOptimizerDiscardObjects is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | discard_objects_options | Optimization related options for discarding objects. 0 means not to do discarding-objects optimization. Please refer to values starting from FSOptimizerSettingsDiscardObjectsFormActions and this can be one or a combination of these values.

Returns
  None.

## ◆ setDiscardUserDataOptions:()

- (void) setDiscardUserDataOptions: |  | (unsigned int) | discard_userdata_options |

Set optimization related options for discarding user data.

For a newly constructed object, if this function is not called to set any discard-userdata options, that means not to do discard-userdata optimization. Discard-userdata options set by this function are useful only when option value FSOptimizerSettingsOptimizerDiscardUserData is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | discard_userdata_options | Optimization related options for discarding user data. 0 means not to do discarding-userdata optimization. Please refer to values starting from FSOptimizerSettingsDiscardUserDataAllAnnotsFormsAndMultimedia and this can be one or a combination of these values.

Returns
  None.

## ◆ setGrayscaleImageSettings:()

- (void) setGrayscaleImageSettings: |  | (FSImageSettings*) | settings |

Set optimization related settings for grayscale image.

For a newly constructed object, if this function is not called to set any grayscale image settings, that means to use default grayscale image settings. Please refer to comment in class FSImageSettings for default values.
FSImageSettings set by this function is useful only when option value FSOptimizerSettingsOptimizerCompressImages is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | settings | Optimization related settings for grayscale images.

Returns
  None.

## ◆ setMonoImageSettings:()

- (void) setMonoImageSettings: |  | (FSMonoImageSettings*) | settings |

Set optimization related settings for monochrome image.

For a newly constructed object, if this function is not called to set any monochrome image settings, that means to use default monochrome image settings. Please refer to comment in class FSMonoImageSettings for detail values.
MonoImageSettings set by this function is useful only when option value FSOptimizerSettingsOptimizerCompressImages is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | settings | Optimization related settings for monochrome images.

Returns
  None.

## ◆ setOptimizerOptions:()

- (void) setOptimizerOptions: |  | (unsigned int) | optimize_options |

Set options to decide which kind of optimizer setting will be used for optimizing PDF document.

For a newly constructed object, if this function is not called to set any optimizer options, that means no optimizer setting is useful.

Parameters

  [in] | optimize_options | The options to decide which kind of optimizer setting will be used for optimizing PDF document. 0 means no optimizer setting of any kind is useful. Please refer to values starting from FSOptimizerSettingsOptimizerCompressImages and this can be one or a combination of these values.

Returns
  None.

## ◆ setTransparencyMode:()

- (void) setTransparencyMode: |  | (FSOptimizerSettingsTransparencyMode) | transparency_mode |

Set optimization related options for doing transparency.

For a newly constructed object, if this function is not called to set any transparency mode, that means the transparency mode is FSOptimizerSettingsTransparencyModeLowResolution default.

Parameters

  [in] | transparency_mode | Optimization related options for transparency mode. Please refer to values starting from FSOptimizerSettingsTransparencyModeLowResolution and this must be one of these values. Default value is FSOptimizerSettingsTransparencyModeLowResolution.

Returns
  None.

## ◆ setUnembeddedFontSettings:()

- (void) setUnembeddedFontSettings: |  | (FSUnembeddedFontSettings*) | settings |

Set optimization related settings for unembedding fonts.

For a newly constructed object, if this function is not called to set any unembedded fonts settings, that means to no font is to be unembedded. UnembeddedFontSettings set by this function is useful only when option value FSOptimizerSettingsOptimizerUnembeddedFonts is set by function FSOptimizerSettings::setOptimizerOptions:.

Parameters

  [in] | settings | Optimization related settings for unembedding fonts.

Returns
  None.