Skip to content

CSS source formatting issue with calc() - Eclipse double Source menu #1490

@KlaasBonnema

Description

@KlaasBonnema

Wild Web Developer HTML, CSS, JSON, Yaml, JavaScript, TypeScript, Node tools 1.3.3.202311211923

Eclipse 2024-03 (4.31.0) will show two Source top menu's while editing a CSS file.
Both menu's have items: Format, Toggle Line Comment, Add Block Comment, Remove Block Comment. The first of the Source menu's has additional items: Shift Left, Shift Right, Cleanup Document, Format Active Elements.
The listed shortcut for Format is Ctrl+Shift+F in both menu's.
There is also a Source->Format command in the documents context menu (right click).

When I use the Format command in the context menu or from the first Source menu (with the larger number of items) the formatting of calc( ) introduces an error by removing a space character.
height: calc(100lvh - var(--header-height) - var(--footer-height));
becomes
height: calc(100lvh - var(--header-height)- var(--footer-height));
which is invalid calc( ) syntax.

When I use the other Format top menu it will leave the space character as it should but it will not correct a missing space character that was taken out previously by the failing Format.

I cannot tell if this occurs using the WWD editor formatting or formatting by another Eclipse component.

Besides this formatting bug it seems there is something wrong with the integration of the Source top menu in Eclipse. There should be only one menu.

Please let me know if this issue should be reported elsewhere, and please tell me where.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions