Coder Social home page Coder Social logo

Comments (2)

maechler avatar maechler commented on May 30, 2024

Unfortunately this is not very easy to implement. Fluid initialises all child ViewHelper arguments (using initializeArguments) before it calls initialize on the top most ViewHelper. But only in the method initialize we get acccess to the ViewHelper arguments that enable us to overwrite the settings. Thus all ViewHelper arguments of the children are already initialized with their corresponding default value before we can overwrite the default settings used.

We would have to rewrite the entire initialization of the ViewHelper arguments, I do not think that this feature is worth that. We should however move some config settings to a ViewHelper where they can be overwritten using Fluid attributes.
The config language and hyphenFile should be moved to the DocumentViewHelper in order to be able to generate multi language PDF documents as a batch job.

config {
class = Bithost\Pdfviewhelpers\Model\EmptyFPDI
language = ger
hyphenFile = hyph-de-ch-1901.tex
disableCache = 1
jpgQuality = 100
sRGBMode = 0
allowedImageTypes {
image = jpg,png,gif
imageEPS = ai,eps
imageSVG = svg
}
fonts {
subset = 1
addTTFFont {
# roboto {
# path = EXT:pdfviewhelpers/Resources/Public/Examples/FullFeatureShowCase/Roboto.ttf
# }
# opensans {
# path = EXT:pdfviewhelpers/Resources/Public/Examples/FullFeatureShowCase/OpenSans.ttf
# }
}
}
}

@macjohnny What do you think?

from pdfviewhelpers.

maechler avatar maechler commented on May 30, 2024

Implemented as suggested.

from pdfviewhelpers.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.