# base/widehat-to-hat

Drop stretchiness from \widehat by rewriting it to \hat.

https://texform.dev/rules/base/widehat-to-hat

## Metadata

| Field | Value |
| --- | --- |
| Key | base/widehat-to-hat |
| Level | equiv |
| Fidelity | math |
| Enabled by packages | base |
| Profiles | Equiv |

## Rewrite patterns

From:

```latex
\widehat{#1}
```

To:

```latex
\hat{#1}
```

## Examples

Examples show the rule in isolation, not a complete normalization profile.

### Wide accent size drop

Before:

```latex
\widehat{AB}
```

After this rule:

```latex
\hat{AB}
```

Packages: base.

The rendered result has pixel differences from the input.

## Triggers

- [\\widehat](https://texform.dev/latex/commands/widehat)

## Eliminates

- [\\widehat](https://texform.dev/latex/commands/widehat)

## Produces

- [\\hat](https://texform.dev/latex/commands/hat)

## Same family

- [ams/substack-expand](https://texform.dev/rules/ams/substack-expand): Expand substack directly to the explicit centered subarray environment.
- [base/buildrel-to-stackrel](https://texform.dev/rules/base/buildrel-to-stackrel): Rewrite plain TeX buildrel syntax to stackrel.
- [base/duplicate-mathrel-wrapper-drop](https://texform.dev/rules/base/duplicate-mathrel-wrapper-drop): Drop one directly nested duplicate mathrel wrapper.
- [base/widetilde-to-tilde](https://texform.dev/rules/base/widetilde-to-tilde): Drop stretchiness from \widetilde by rewriting it to \tilde.
- [base/stackbin-expand](https://texform.dev/rules/base/stackbin-expand): Expand stackbin to an explicit binary-level stacked operator form.
- [base/stackrel-expand](https://texform.dev/rules/base/stackrel-expand): Expand stackrel to an explicit relation-level stacked operator form.

## Notes

The wide and short forms retain the same accent identity and mathematical attachment to the same body. For an arbitrary multi-symbol body, however, the wide extent is a visible scope cue; replacing it with a short accent can weaken readability and make the intended span less apparent. The rule therefore first enters Equiv and claims only Math fidelity.

## Disable this rule

```python
TransformEngine(profile="corpus", disable_rules=["base/widehat-to-hat"])
```

```javascript
new TransformEngine({ profile: 'corpus', disableRules: ['base/widehat-to-hat'] })
```

[Open in Playground](https://play.texform.dev/?input=%5Cwidehat%7BAB%7D)
