| OLD | NEW |
| 1 /* | 1 /* |
| 2 ****************************************************************************** | 2 ****************************************************************************** |
| 3 * | 3 * |
| 4 * Copyright (C) 1999-2013, International Business Machines | 4 * Copyright (C) 1999-2014, International Business Machines |
| 5 * Corporation and others. All Rights Reserved. | 5 * Corporation and others. All Rights Reserved. |
| 6 * | 6 * |
| 7 ****************************************************************************** | 7 ****************************************************************************** |
| 8 * file name: ubidiln.c | 8 * file name: ubidiln.c |
| 9 * encoding: US-ASCII | 9 * encoding: US-ASCII |
| 10 * tab size: 8 (not used) | 10 * tab size: 8 (not used) |
| 11 * indentation:4 | 11 * indentation:4 |
| 12 * | 12 * |
| 13 * created on: 1999aug06 | 13 * created on: 1999aug06 |
| 14 * created by: Markus W. Scherer, updated by Matitiahu Allouche | 14 * created by: Markus W. Scherer, updated by Matitiahu Allouche |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 are already set to paragraph level. | 103 are already set to paragraph level. |
| 104 Setting trailingWSStart to pBidi->length will avoid changing the | 104 Setting trailingWSStart to pBidi->length will avoid changing the |
| 105 level of B chars from 0 to paraLevel in ubidi_getLevels when | 105 level of B chars from 0 to paraLevel in ubidi_getLevels when |
| 106 orderParagraphsLTR==TRUE. | 106 orderParagraphsLTR==TRUE. |
| 107 */ | 107 */ |
| 108 if(dirProps[start-1]==B) { | 108 if(dirProps[start-1]==B) { |
| 109 pBiDi->trailingWSStart=start; /* currently == pBiDi->length */ | 109 pBiDi->trailingWSStart=start; /* currently == pBiDi->length */ |
| 110 return; | 110 return; |
| 111 } | 111 } |
| 112 /* go backwards across all WS, BN, explicit codes */ | 112 /* go backwards across all WS, BN, explicit codes */ |
| 113 while(start>0 && DIRPROP_FLAG(PURE_DIRPROP(dirProps[start-1]))&MASK_WS) { | 113 while(start>0 && DIRPROP_FLAG(dirProps[start-1])&MASK_WS) { |
| 114 --start; | 114 --start; |
| 115 } | 115 } |
| 116 | 116 |
| 117 /* if the WS run can be merged with the previous run then do so here */ | 117 /* if the WS run can be merged with the previous run then do so here */ |
| 118 while(start>0 && levels[start-1]==paraLevel) { | 118 while(start>0 && levels[start-1]==paraLevel) { |
| 119 --start; | 119 --start; |
| 120 } | 120 } |
| 121 | 121 |
| 122 pBiDi->trailingWSStart=start; | 122 pBiDi->trailingWSStart=start; |
| 123 } | 123 } |
| (...skipping 1218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1342 pi=srcMap+length; | 1342 pi=srcMap+length; |
| 1343 while(length>0) { | 1343 while(length>0) { |
| 1344 if(*--pi>=0) { | 1344 if(*--pi>=0) { |
| 1345 destMap[*pi]=--length; | 1345 destMap[*pi]=--length; |
| 1346 } else { | 1346 } else { |
| 1347 --length; | 1347 --length; |
| 1348 } | 1348 } |
| 1349 } | 1349 } |
| 1350 } | 1350 } |
| 1351 } | 1351 } |
| OLD | NEW |