Skip to content

Commit f51f6e2

Browse files
committed
Fix osdn.net ticket #47553: Allow text to wrap in the Table Compare Window and unwrap lines in the Text Compare Window
1 parent ada4b9b commit f51f6e2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+128
-3
lines changed

Src/Merge.rc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4000,6 +4000,11 @@ BEGIN
40004000
IDS_WEBPAGE_MENU "We&bpage"
40014001
END
40024002

4003+
STRINGTABLE
4004+
BEGIN
4005+
IDS_VIEW_WRAP_TEXT "W&rap Text"
4006+
END
4007+
40034008
STRINGTABLE
40044009
BEGIN
40054010
IDS_FRHED_NOTINSTALLED "Frhed is not installed."

Src/MergeEditView.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3572,7 +3572,9 @@ void CMergeEditView::OnUpdateViewLineNumbers(CCmdUI* pCmdUI)
35723572
*/
35733573
void CMergeEditView::OnViewWordWrap()
35743574
{
3575-
GetOptionsMgr()->SaveOption(OPT_WORDWRAP, !m_bWordWrap);
3575+
GetOptionsMgr()->SaveOption(
3576+
GetDocument()->m_ptBuf[0]->GetTableEditing() ? OPT_WORDWRAP_TABLE : OPT_WORDWRAP,
3577+
!m_bWordWrap);
35763578

35773579
// Call CMergeDoc RefreshOptions() to refresh *both* views
35783580
CMergeDoc *pDoc = GetDocument();
@@ -3586,6 +3588,8 @@ void CMergeEditView::OnUpdateViewWordWrap(CCmdUI* pCmdUI)
35863588
{
35873589
pCmdUI->Enable(true);
35883590
pCmdUI->SetCheck(m_bWordWrap);
3591+
pCmdUI->SetText((GetDocument()->m_ptBuf[0]->GetTableEditing() ?
3592+
_("W&rap Text") : _("W&rap Lines")).c_str());
35893593
}
35903594

35913595
void CMergeEditView::OnViewWhitespace()
@@ -3883,7 +3887,8 @@ void CMergeEditView::DocumentsLoaded()
38833887
const bool mixedEOLs = GetOptionsMgr()->GetBool(OPT_ALLOW_MIXED_EOL) ||
38843888
GetDocument()->IsMixedEOL(m_nThisPane);
38853889
SetViewEols(GetOptionsMgr()->GetBool(OPT_VIEW_EOL), mixedEOLs);
3886-
SetWordWrapping(GetOptionsMgr()->GetBool(OPT_WORDWRAP));
3890+
SetWordWrapping(GetOptionsMgr()->GetBool(GetDocument()->m_ptBuf[m_nThisPane]->GetTableEditing() ?
3891+
OPT_WORDWRAP_TABLE : OPT_WORDWRAP));
38873892
SetViewLineNumbers(GetOptionsMgr()->GetBool(OPT_VIEW_LINENUMBERS));
38883893
SetSelectionMargin(GetOptionsMgr()->GetBool(OPT_VIEW_FILEMARGIN));
38893894

Src/OptionsDef.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ inline const String OPT_COPY_FULL_LINE {_T("Settings/CopyFullLine"s)};
8282
inline const String OPT_TAB_SIZE {_T("Settings/TabSize"s)};
8383
inline const String OPT_TAB_TYPE {_T("Settings/TabType"s)};
8484
inline const String OPT_WORDWRAP {_T("Settings/WordWrap"s)};
85+
inline const String OPT_WORDWRAP_TABLE {_T("Settings/WordWrapTable"s)};
8586
inline const String OPT_VIEW_LINENUMBERS {_T("Settings/ViewLineNumbers"s)};
8687
inline const String OPT_VIEW_FILEMARGIN {_T("Settings/ViewFileMargin"s)};
8788
inline const String OPT_VIEW_TOPMARGIN {_T("Settings/ViewTopMargin"s)};

Src/OptionsInit.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ void Init(COptionsMgr *pOptions)
7171

7272
pOptions->InitOption(OPT_SYNTAX_HIGHLIGHT, true);
7373
pOptions->InitOption(OPT_WORDWRAP, false);
74+
pOptions->InitOption(OPT_WORDWRAP_TABLE, false);
7475
pOptions->InitOption(OPT_VIEW_LINENUMBERS, false);
7576
pOptions->InitOption(OPT_VIEW_WHITESPACE, false);
7677
pOptions->InitOption(OPT_VIEW_EOL, false);

Src/resource.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1485,6 +1485,7 @@
14851485
#define IDS_EOL_CONFLICT 43247
14861486
#define IDS_IMAGE_MENU 43352
14871487
#define IDS_WEBPAGE_MENU 43353
1488+
#define IDS_VIEW_WRAP_TEXT 43354
14881489
#define IDS_EOL_DOS 43400
14891490
#define IDS_EOL_MAC 43401
14901491
#define IDS_EOL_UNIX 43402

Testing/GoogleTest/GUITests/ConfigTest.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,7 @@ namespace
162162
{ OPT_TAB_SIZE, varprop::VT_INT, {1, 2, 4, 8, 128}, {} },
163163
{ OPT_TAB_TYPE, varprop::VT_INT, {0, 1}, {} },
164164
{ OPT_WORDWRAP, varprop::VT_BOOL, {}, {} },
165+
{ OPT_WORDWRAP_TABLE, varprop::VT_BOOL, {}, {} },
165166
{ OPT_VIEW_LINENUMBERS, varprop::VT_BOOL, {}, {} },
166167
{ OPT_VIEW_FILEMARGIN, varprop::VT_BOOL, {}, {} },
167168
{ OPT_DIFF_CONTEXT, varprop::VT_INT, {0, 1, 3, 5, 7, 9}, {} },

Translations/WinMerge/Arabic.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3705,6 +3705,9 @@ msgstr "&تفعيل النطاق الأقصى التلقائي"
37053705
msgid "We&bpage"
37063706
msgstr ""
37073707

3708+
msgid "W&rap Text"
3709+
msgstr ""
3710+
37083711
msgid "Frhed is not installed."
37093712
msgstr "المحرر Frhed غير مثبت."
37103713

Translations/WinMerge/Basque.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4315,6 +4315,9 @@ msgstr ""
43154315
msgid "We&bpage"
43164316
msgstr ""
43174317

4318+
msgid "W&rap Text"
4319+
msgstr ""
4320+
43184321
msgid "Frhed is not installed."
43194322
msgstr ""
43204323

Translations/WinMerge/Brazilian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3393,6 +3393,9 @@ msgstr "Ativar o &Máximo de Largura Automática"
33933393
msgid "We&bpage"
33943394
msgstr "Página Web"
33953395

3396+
msgid "W&rap Text"
3397+
msgstr ""
3398+
33963399
msgid "Frhed is not installed."
33973400
msgstr "O Frhed não está instalado."
33983401

Translations/WinMerge/Bulgarian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3789,6 +3789,9 @@ msgstr "Автоматична &максимална ширина"
37893789
msgid "We&bpage"
37903790
msgstr ""
37913791

3792+
msgid "W&rap Text"
3793+
msgstr ""
3794+
37923795
msgid "Frhed is not installed."
37933796
msgstr "Frhed не е инсталиран."
37943797

Translations/WinMerge/Catalan.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4464,6 +4464,9 @@ msgstr "Activa l'amplada màxima automàtica"
44644464
msgid "We&bpage"
44654465
msgstr ""
44664466

4467+
msgid "W&rap Text"
4468+
msgstr ""
4469+
44674470
msgid "Frhed is not installed."
44684471
msgstr "L'aplicació Frhed no està instal·lada."
44694472

Translations/WinMerge/ChineseSimplified.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3809,6 +3809,9 @@ msgstr "启用自动最大宽度(&A)"
38093809
msgid "We&bpage"
38103810
msgstr "网页(&B)"
38113811

3812+
msgid "W&rap Text"
3813+
msgstr ""
3814+
38123815
msgid "Frhed is not installed."
38133816
msgstr "Frhed 未安装。"
38143817

Translations/WinMerge/ChineseTraditional.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4463,6 +4463,9 @@ msgstr "開啟自動最大寬度 (&A)"
44634463
msgid "We&bpage"
44644464
msgstr ""
44654465

4466+
msgid "W&rap Text"
4467+
msgstr ""
4468+
44664469
msgid "Frhed is not installed."
44674470
msgstr "Frhed 未安裝。"
44684471

Translations/WinMerge/Corsican.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3780,6 +3780,9 @@ msgstr "&Attivà a larghezza massima autumatica"
37803780
msgid "We&bpage"
37813781
msgstr "Pagina we&b"
37823782

3783+
msgid "W&rap Text"
3784+
msgstr ""
3785+
37833786
msgid "Frhed is not installed."
37843787
msgstr "Frhed ùn hè micca installatu."
37853788

Translations/WinMerge/Croatian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4314,6 +4314,9 @@ msgstr ""
43144314
msgid "We&bpage"
43154315
msgstr ""
43164316

4317+
msgid "W&rap Text"
4318+
msgstr ""
4319+
43174320
msgid "Frhed is not installed."
43184321
msgstr ""
43194322

Translations/WinMerge/Czech.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4247,6 +4247,9 @@ msgstr ""
42474247
msgid "We&bpage"
42484248
msgstr ""
42494249

4250+
msgid "W&rap Text"
4251+
msgstr ""
4252+
42504253
msgid "Frhed is not installed."
42514254
msgstr ""
42524255

Translations/WinMerge/Danish.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4352,6 +4352,9 @@ msgstr ""
43524352
msgid "We&bpage"
43534353
msgstr ""
43544354

4355+
msgid "W&rap Text"
4356+
msgstr ""
4357+
43554358
msgid "Frhed is not installed."
43564359
msgstr ""
43574360

Translations/WinMerge/Dutch.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3787,6 +3787,9 @@ msgstr "Automatische maximale breedte inschakelen"
37873787
msgid "We&bpage"
37883788
msgstr ""
37893789

3790+
msgid "W&rap Text"
3791+
msgstr ""
3792+
37903793
msgid "Frhed is not installed."
37913794
msgstr "Fhred is niet geïnstalleerd"
37923795

Translations/WinMerge/English.pot

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ msgid ""
55
msgstr ""
66
"Project-Id-Version: WinMerge\n"
77
"Report-Msgid-Bugs-To: https://bugs.winmerge.org/\n"
8-
"POT-Creation-Date: 2023-02-19 08:57+0000\n"
8+
"POT-Creation-Date: 2023-03-12 11:58+0000\n"
99
"PO-Revision-Date: \n"
1010
"Last-Translator: \n"
1111
"Language-Team: English <[email protected]>\n"
@@ -3387,6 +3387,9 @@ msgstr ""
33873387
msgid "We&bpage"
33883388
msgstr ""
33893389

3390+
msgid "W&rap Text"
3391+
msgstr ""
3392+
33903393
msgid "Frhed is not installed."
33913394
msgstr ""
33923395

Translations/WinMerge/Finnish.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3798,6 +3798,9 @@ msgstr "Käytä &automaattista maksimi leveyttä"
37983798
msgid "We&bpage"
37993799
msgstr "Ver&kkosivu"
38003800

3801+
msgid "W&rap Text"
3802+
msgstr ""
3803+
38013804
msgid "Frhed is not installed."
38023805
msgstr "Frhed ei ole asennettu."
38033806

Translations/WinMerge/French.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4491,6 +4491,9 @@ msgstr "Activer largeur &auto max"
44914491
msgid "We&bpage"
44924492
msgstr "Page &web"
44934493

4494+
msgid "W&rap Text"
4495+
msgstr ""
4496+
44944497
msgid "Frhed is not installed."
44954498
msgstr "Frhed n'est pas installé."
44964499

Translations/WinMerge/Galician.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4486,6 +4486,9 @@ msgstr "Activar &anchura máxima automática"
44864486
msgid "We&bpage"
44874487
msgstr "Páxina we&b"
44884488

4489+
msgid "W&rap Text"
4490+
msgstr ""
4491+
44894492
msgid "Frhed is not installed."
44904493
msgstr "Frhed non está instalado."
44914494

Translations/WinMerge/German.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4110,6 +4110,9 @@ msgstr "Automatisch maximale Breite aktivieren"
41104110
msgid "We&bpage"
41114111
msgstr "We&bseite"
41124112

4113+
msgid "W&rap Text"
4114+
msgstr ""
4115+
41134116
msgid "Frhed is not installed."
41144117
msgstr "Frhed ist nicht installiert."
41154118

Translations/WinMerge/Greek.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4292,6 +4292,9 @@ msgstr ""
42924292
msgid "We&bpage"
42934293
msgstr ""
42944294

4295+
msgid "W&rap Text"
4296+
msgstr ""
4297+
42954298
msgid "Frhed is not installed."
42964299
msgstr ""
42974300

Translations/WinMerge/Hungarian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4448,6 +4448,9 @@ msgstr "Auto oszlopszélesség be"
44484448
msgid "We&bpage"
44494449
msgstr "Weboldal"
44504450

4451+
msgid "W&rap Text"
4452+
msgstr ""
4453+
44514454
msgid "Frhed is not installed."
44524455
msgstr "Az Frhed hexa szerkesztő nincs telepítve."
44534456

Translations/WinMerge/Italian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3744,6 +3744,9 @@ msgstr "Abilita altezza massima &automatica"
37443744
msgid "We&bpage"
37453745
msgstr "Pagina we&b"
37463746

3747+
msgid "W&rap Text"
3748+
msgstr ""
3749+
37473750
msgid "Frhed is not installed."
37483751
msgstr "Frhed non è installato."
37493752

Translations/WinMerge/Japanese.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3771,6 +3771,9 @@ msgstr "タブ幅の自動調整を有効にする(&A)"
37713771
msgid "We&bpage"
37723772
msgstr "Webページ(&B)"
37733773

3774+
msgid "W&rap Text"
3775+
msgstr "折り返して全体を表示(&R)"
3776+
37743777
msgid "Frhed is not installed."
37753778
msgstr "Frhed がインストールされていません。"
37763779

Translations/WinMerge/Korean.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4489,6 +4489,9 @@ msgstr "자동 최대 너비 사용(&A)"
44894489
msgid "We&bpage"
44904490
msgstr "웹페이지(&B)"
44914491

4492+
msgid "W&rap Text"
4493+
msgstr ""
4494+
44924495
msgid "Frhed is not installed."
44934496
msgstr "Frhed가 설치되지 않았습니다."
44944497

Translations/WinMerge/Lithuanian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3393,6 +3393,9 @@ msgstr "Įjungti &Automatinį maks. plotį"
33933393
msgid "We&bpage"
33943394
msgstr "Ti&nklapiai"
33953395

3396+
msgid "W&rap Text"
3397+
msgstr ""
3398+
33963399
msgid "Frhed is not installed."
33973400
msgstr "„Frhed“ neįdiegtas."
33983401

Translations/WinMerge/Norwegian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3777,6 +3777,9 @@ msgstr ""
37773777
msgid "We&bpage"
37783778
msgstr ""
37793779

3780+
msgid "W&rap Text"
3781+
msgstr ""
3782+
37803783
msgid "Frhed is not installed."
37813784
msgstr ""
37823785

Translations/WinMerge/Persian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4361,6 +4361,9 @@ msgstr ""
43614361
msgid "We&bpage"
43624362
msgstr ""
43634363

4364+
msgid "W&rap Text"
4365+
msgstr ""
4366+
43644367
msgid "Frhed is not installed."
43654368
msgstr ""
43664369

Translations/WinMerge/Polish.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3394,6 +3394,9 @@ msgstr "Włącz automatycznie maksymalną szerokość"
33943394
msgid "We&bpage"
33953395
msgstr "Strona internetowa"
33963396

3397+
msgid "W&rap Text"
3398+
msgstr ""
3399+
33973400
msgid "Frhed is not installed."
33983401
msgstr "Free Hex Editor nie został zainstalowany."
33993402

Translations/WinMerge/Portuguese.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3814,6 +3814,9 @@ msgstr "Ativar largura máxima automática"
38143814
msgid "We&bpage"
38153815
msgstr "&Página web"
38163816

3817+
msgid "W&rap Text"
3818+
msgstr ""
3819+
38173820
msgid "Frhed is not installed."
38183821
msgstr "O Frhed não está instalado."
38193822

Translations/WinMerge/Romanian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4297,6 +4297,9 @@ msgstr ""
42974297
msgid "We&bpage"
42984298
msgstr ""
42994299

4300+
msgid "W&rap Text"
4301+
msgstr ""
4302+
43004303
msgid "Frhed is not installed."
43014304
msgstr ""
43024305

Translations/WinMerge/Russian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3395,6 +3395,9 @@ msgstr "Включить максимальную авто ширину"
33953395
msgid "We&bpage"
33963396
msgstr "Веб-страница"
33973397

3398+
msgid "W&rap Text"
3399+
msgstr ""
3400+
33983401
msgid "Frhed is not installed."
33993402
msgstr "Frhed не установлен."
34003403

Translations/WinMerge/Serbian.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4286,6 +4286,9 @@ msgstr ""
42864286
msgid "We&bpage"
42874287
msgstr ""
42884288

4289+
msgid "W&rap Text"
4290+
msgstr ""
4291+
42894292
msgid "Frhed is not installed."
42904293
msgstr ""
42914294

Translations/WinMerge/Sinhala.po

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4315,6 +4315,9 @@ msgstr ""
43154315
msgid "We&bpage"
43164316
msgstr ""
43174317

4318+
msgid "W&rap Text"
4319+
msgstr ""
4320+
43184321
msgid "Frhed is not installed."
43194322
msgstr ""
43204323

0 commit comments

Comments
 (0)