Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Changed

- fj-doc-mod-openpdf-ext, producer is now 'Venus Fugerit Doc over OpenPDF'
- fj-doc-mod-openpdf-ext, default creator is now 'Venus Fugerit Doc (<https://github.com/fugerit-org/fj-doc>)'

### Fixed

- fj-doc-mod-openpdf-ext - OpenPDF alignment not set by type handler <https://github.com/fugerit-org/fj-doc/issues/517>

## [8.16.4] - 2025-09-25

### Fixed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ public class DocConfig {
public DocConfig() {
this.versionConfig = VERSION;
}


public static final String FUGERIT_VENUS_DOC = "Venus Fugerit Doc";

public static final String VERSION = " FUGERIT DOC Version 2.1 (2023-08-19) ";

public static final String TYPE_XML = "xml";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public void registerHandler( DocTypeHandler handler, boolean registerForType, bo
if ( errorOnDuplicate ) {
throw new ConfigException( "Duplicate handler for format : "+format+" (type:"+type+")" );
} else {
log.warn( "Warning duplicate handler for format, {} will replace {}", format, handler.getKey(), previous.getKey() );
log.warn( "Warning duplicate handler for format {}, {} will replace {}", format, handler.getKey(), previous.getKey() );
}
}
doRegister(handler, format);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ Whereas the link:https://github.com/fugerit-org/fj-doc/blob/main/CHANGELOG.md[CH
[#doc-release-notes-unreleased]
==== Unreleased

- fj-doc-mod-openpdf-ext - OpenPDF alignment not set by type handler link:https://github.com/fugerit-org/fj-doc/issues/517[#517]

[#doc-release-notes-8-16-4]
==== Version 8.16.4 [2025-09-25]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@
import com.lowagie.text.Document;
import org.fugerit.java.core.function.SafeFunction;
import org.fugerit.java.core.function.UnsafeConsumer;
import org.fugerit.java.doc.base.config.DocConfig;
import org.fugerit.java.doc.base.model.DocBase;
import org.fugerit.java.doc.base.typehelper.generic.GenericConsts;

public class DocumentMetaHelper {

private DocumentMetaHelper() {}

public static final String CREATOR_DEFAULT = "OpenPDF over Fugerit Venus DOC";
public static final String CREATOR_DEFAULT = String.format( "%s (https://github.com/fugerit-org/fj-doc)", DocConfig.FUGERIT_VENUS_DOC );

public static final String PRODUCER_DEFAULT = String.format( "%s over %s", DocConfig.FUGERIT_VENUS_DOC , Document.getProduct() );

private static void metaWorker(String property, UnsafeConsumer<String, Exception> fun ) {
SafeFunction.applyIfNotNull( property, () -> fun.accept( property ) );
Expand All @@ -33,7 +36,7 @@ public static void handleDocMeta(Document document, DocBase docBase) {
metaWorker(
docBase.getStableInfo().getProperty(GenericConsts.INFO_KEY_DOC_CREATOR, CREATOR_DEFAULT),
document::addCreator );

document.addProducer( PRODUCER_DEFAULT );
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ protected static Image createImage( DocImage docImage ) {
if ( docImage.getScaling() != null ) {
image.scalePercent( docImage.getScaling().floatValue() );
}
image.setAlignment( getAlign( docImage.getAlign() ) );
return image;
} );
}
Expand Down