Skip to content

Unify rule and linear layers#252

Open
teunbrand wants to merge 12 commits intoposit-dev:mainfrom
teunbrand:unify_rule_linear
Open

Unify rule and linear layers#252
teunbrand wants to merge 12 commits intoposit-dev:mainfrom
teunbrand:unify_rule_linear

Conversation

@teunbrand
Copy link
Collaborator

This PR aims to fix #220.

It adds slope and intercept parameters to the rule layer, and removes the linear layer.
At time of writing, I still have to trivialise intercept per discussion.

teunbrand and others added 12 commits March 20, 2026 13:44
…hetics

When annotation layers have no required aesthetics (e.g., rule geom) and only
non-positional scalar parameters, process_annotation_layer now adds a dummy
column to generate valid SQL instead of malformed empty VALUES clause.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
/// This method is called during layer execution to allow geoms to customize
/// how aesthetics and parameters should be treated. The default implementation
/// does nothing.
fn setup_layer(
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought this would be a nice hook for layers to check combinations of parameters and combinations of aeshtetics. A bunch of such checks are in the writer, but they'd generalise to other writers too.

@teunbrand teunbrand marked this pull request as ready for review March 20, 2026 18:20
@teunbrand teunbrand requested a review from thomasp85 March 20, 2026 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

linear layer should use slope?

1 participant