Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

Transform cage incorrect when layer has zero width

Aberta
#4,619 2 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
3/5
Tempo estimado
1-2 dias
Facilidade para iniciantes
76/100
Tipo de issue
Bug
Clareza
Claramente especificada
Status de atividade
Ativa
Stack de tecnologia
rust

Direção de pesquisa

Reproduce the zero-width layer case with the listed rectangle and select-tool steps, then read the transform handling in node-graph/libraries/rendering/src/renderer.rs around line 3293 and editor/src/messages/tool/tool_messages/select_tool.rs around lines 771-774. Compare the two singular-transform paths and verify that the transform cage remains aligned without the reported offset when the scale is zero.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Reproduction

  • New document
  • Draw rectangle
  • Switch select tool
  • s x 0 (or set the scale x to be zero in the properties panel).
  • Observe transform bounds/cage offset

Video

https://github.com/user-attachments/assets/56e9ec75-549a-435d-8293-a3cf434e7377

Relevant code

When putting into the click targets, the inverse of the transform is applied. However if det=0 then the identity is used:
https://github.com/GraphiteEditor/Graphite/blob/ae321b3409113b238f1482a5ad71cbfff6929602/node-graph/libraries/rendering/src/renderer.rs#L3293
However in the select tool if the transform det=0, a random small number is added to it and the inverse of that transform is used:
https://github.com/GraphiteEditor/Graphite/blob/ae321b3409113b238f1482a5ad71cbfff6929602/editor/src/messages/tool/tool_messages/select_tool.rs#L771-L774

This has the effect of applying any translation twice for the bounding box when det=0.

Linguagem predominante
Rust
Estrelas
27.3k
Forks
1.3k
Merge médio
16h 57min
PRs com merge (30d)
87

Preparar o ambiente

Ainda não verificamos os arquivos de configuração deste projeto. Comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de GraphiteEditor/Graphite

Todas as issues de GraphiteEditor/Graphite

Issues semelhantes

Mais issues de Rust

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.