From df9481b3d93176ed943a68ae8ddf4bbec4c92eef Mon Sep 17 00:00:00 2001 From: David Bailes Date: Sat, 6 Jun 2015 11:52:04 +0100 Subject: [PATCH] Fix for accessibility names of tracks due to problems with translations. The strings for mute on, solo on, etc contained a leading space. Many of the translations of these strings did not include the leading space, resulting in merged words. Therefore a space has been added as a separate string. Because screen readers are not affected by multiple spaces, the leading spaces have been left in the original strings so that no new translations are needed. --- src/TrackPanelAx.cpp | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/TrackPanelAx.cpp b/src/TrackPanelAx.cpp index 2099024d5..6fbb0cfb5 100644 --- a/src/TrackPanelAx.cpp +++ b/src/TrackPanelAx.cpp @@ -307,22 +307,28 @@ wxAccStatus TrackPanelAx::GetName( int childId, wxString* name ) // LLL: Remove these during "refactor" if( t->GetMute() ) { + // The following comment also applies to the solo, selected, + // and synclockselected states. + // Many of translations of the strings with a leading space omitted + // the leading space. Therefore a space has been added using wxT(" "). + // Because screen readers won't be affected by multiple spaces, the + // leading spaces have not been removed, so that no new translations are needed. /* i18n-hint: This is for screen reader software and indicates that on this track mute is on.*/ - name->Append( _( " Mute On" ) ); + name->Append( wxT(" ") + wxString(_( " Mute On" )) ); } if( t->GetSolo() ) { /* i18n-hint: This is for screen reader software and indicates that on this track solo is on.*/ - name->Append( _( " Solo On" ) ); + name->Append( wxT(" ") + wxString(_( " Solo On" )) ); } if( t->GetSelected() ) { /* i18n-hint: This is for screen reader software and indicates that this track is selected.*/ - name->Append( _( " Select On" ) ); + name->Append( wxT(" ") + wxString(_( " Select On" )) ); } if( t->IsSyncLockSelected() ) { @@ -330,7 +336,7 @@ wxAccStatus TrackPanelAx::GetName( int childId, wxString* name ) this track is shown with a sync-locked icon.*/ // The absence of a dash between Sync and Locked is deliberate - // if present, Jaws reads it as "dash". - name->Append( _( " Sync Lock Selected" ) ); + name->Append( wxT(" ") + wxString(_( " Sync Lock Selected" )) ); } } }