Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions TeXmacs/progs/table/table-menu.scm
Original file line number Diff line number Diff line change
Expand Up @@ -668,3 +668,18 @@
((balloon (icon "tm_cell_join.xpm")
"Join selected cells")
(cell-set-span-selection)))))
(tm-menu (focus-toggle-icons t)
(:require (table-markup-context? t))
(push-focus t
(assuming (numbered-context? t)
((check (balloon (icon "tm_numbered.xpm") "Toggle cell alignment") "v"
(pull-focus t
(numbered-numbered? t)))
(pull-focus t (numbered-toggle t))))))
(tm-define (alternate-first-icon t)
(:require (table-markup-context? t))
"tm_cell_left.xpm")

(tm-define (alternate-second-icon t)
(:require (table-markup-context? t))
"tm_cell_center.xpm")
26 changes: 12 additions & 14 deletions devel/222_51.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
# 222_51 Translate 'Text for Note' into chinese
# [222_51] Fix misleading tooltip in tabular context

### What
Translates the option `Text for note` found at `Insert -> Link -> Text for note`
## What
The tooltip "Toggle numbering" was misleading in tabular context.

### Why
The option is in plain english and needs to be translated into chinese.
## Why
The button actually toggles cell alignment (tabular vs tabular*), not numbering.

### How
In `TeXmacs/plugins/lang/dic/en_US/zh_CN.scm` added the translation:

```diff
+ ("Text for note" "用于笔记的文本")
```
## How
Added a table-specific override in table-menu.scm using (:require (table-markup-context? t))

## How to test
1. Open Mogan and click on `插入` or `Insert`
2. Go to `链接` or `Link`
3. In the options, `Text for note` has been translated into `用于笔记的文本`
1. Open Mogan
2. Insert a table: Insert + Table + Plain tabular
3. Click inside the table
4. Check the focus toolbar – the tooltip should now say "Toggle cell alignment" instead of "Toggle numbering"