• Resolved marcoba

    (@marcoba)


    Is possible to change the initial font and font sample feature options through shortcode or javascript? Or you have to create different fontsamplers?

    The ideia is to have a page with a little preview with only font size options, and in the content page various fontsamplers with full features and different initial fonts.

    Thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author kontur

    (@kontur)

    You can set the default text with an additional shortcode parameter, like so:

    [fontsampler id=999 text="Lorem ipsum"]

    The logic for setting the font like this is a bit more complicated, but it is also possible, given that you have the path to the font. I implemented this options mostly for developers that might use WordPress’ do_shortcode() function, but the principle is the same:

    [fontsampler fonts="{"woff":"json-encoded/path-to/fontfile.woff", "name":"Display name of the font", "initial":true},{"woff":"json-encoded/path-to/another-fontfile.woff", "name":"Display name of the other font", "initial":false}"]

    I suppose these do what you are asking for? ??

    Best,
    Johannes

    Plugin Author kontur

    (@kontur)

    I’ll mark this issue as resolved since I have not heard back from you. Please reopen a new topic with more information if the above approach does not work for you.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Change Options’ is closed to new replies.