Skip to content

[css-conditional-5] Remove definitions of <font-format> and <font-tech> #8110

Closed

Description

@cdoublev

Would it be possible to remove the definitions of <font-format> and <font-tech> from CSS Conditional 5?

The spec says:

This level of the specification extends the <supports-feature> syntax

But it does not extend these subproductions. Worse: <font-format> is only a subset of what is defined in CSS Fonts.

These duplicate definitions must be specifically handled in w3c/webref, by defining an "authoritative source" for the production, which is not great.

Activity

  1. drott commented on Nov 29, 2022

    @drott
    Collaborator

    Worse: is only a subset of what is defined in CSS Fonts.

    Are you referring to the <string> production? This is the legacy part of format() which is intentionally not included in the conditionals definition.

    Regarding the PR: What does the spec look like after bikeshed processing - do the font-tech and font-format become clickable references to fonts-4? font-format would then no longer be correctly defined.

  2. cdoublev commented on Nov 29, 2022

    @cdoublev
    CollaboratorAuthor

    Are you referring to the <string> production?

    Yes. Should it be invalid in @supports but valid in src for @font-face?

    If so, I will close my PR but I think it should be defined in prose (more simple) or in the syntax. I think rewriting the syntax would require to not define font-tech() as a type (<font-tech()> = ...) but as a context-sensitive function (font-tech() = ...).

    I did not check the result in Bikeshed, which reports an error for duplicate type refs of <font-tech> in CSS Conditional 5 and CSS Fonts 5, and generates a link to CSS Fonts 5 for <font-format>. I do not know well how it works in details and I do not really understand why it generates a link to CSS Fonts 5 for <font-format> but not <font-tech>.

  3. cdoublev commented on Apr 26, 2023

    @cdoublev
    CollaboratorAuthor

    I updated the PR to import <font-format> and <font-tech> from CSS Fonts by defining that "a CSS processor is considered to support a font format when it is capable of utilising the specified font format in layout and rendering, and this format is not specified as a <string>", which is similar to the prose excluding an unknown -webkit pseudo-element for a supported selector.

  4. vitorroriz commented on May 8, 2023

    @vitorroriz

    At https://www.w3.org/TR/css-conditional-5/#at-supports-ext, It is confusing for me to read:

    Note: The allowed values for the font-format() function are the same as those for the format() function in the '@font-face' src descriptor.

    Given that at @font-face src we accept <string> for legacy reasons.

  5. self-assigned this
    on May 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions