| OLD | NEW |
| 1 /* ***** BEGIN LICENSE BLOCK ***** | 1 /* ***** BEGIN LICENSE BLOCK ***** |
| 2 * | 2 * |
| 3 * Copyright (C) 2015 The Android Open Source Project | 3 * Copyright (C) 2015 The Android Open Source Project |
| 4 * | 4 * |
| 5 * Licensed under the Apache License, Version 2.0 (the "License"); | 5 * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 * you may not use this file except in compliance with the License. | 6 * you may not use this file except in compliance with the License. |
| 7 * You may obtain a copy of the License at | 7 * You may obtain a copy of the License at |
| 8 * | 8 * |
| 9 * http://www.apache.org/licenses/LICENSE-2.0 | 9 * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 * | 10 * |
| 11 * Unless required by applicable law or agreed to in writing, software | 11 * Unless required by applicable law or agreed to in writing, software |
| 12 * distributed under the License is distributed on an "AS IS" BASIS, | 12 * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 * See the License for the specific language governing permissions and | 14 * See the License for the specific language governing permissions and |
| 15 * limitations under the License. | 15 * limitations under the License. |
| 16 * | 16 * |
| 17 * ***** END LICENSE BLOCK ***** */ | 17 * ***** END LICENSE BLOCK ***** */ |
| 18 | 18 |
| 19 #include <unicode/uchar.h> |
| 20 #include <algorithm> |
| 21 #include <memory> |
| 22 #include <string> |
| 19 #include <vector> | 23 #include <vector> |
| 20 #include <memory> | |
| 21 #include <algorithm> | |
| 22 #include <string> | |
| 23 #include <unicode/uchar.h> | |
| 24 | 24 |
| 25 // HACK: for reading pattern file | 25 // HACK: for reading pattern file |
| 26 #include <fcntl.h> | 26 #include <fcntl.h> |
| 27 | 27 |
| 28 #include "platform/text/hyphenation/HyphenatorAOSP.h" | 28 #include "platform/text/hyphenation/HyphenatorAOSP.h" |
| 29 | 29 |
| 30 using std::vector; | 30 using std::vector; |
| 31 | 31 |
| 32 namespace android { | 32 namespace android { |
| 33 | 33 |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 } | 240 } |
| 241 } | 241 } |
| 242 // Since the above calculation does not modify values outside | 242 // Since the above calculation does not modify values outside |
| 243 // [MIN_PREFIX, len - MIN_SUFFIX], they are left as 0. | 243 // [MIN_PREFIX, len - MIN_SUFFIX], they are left as 0. |
| 244 for (size_t i = MIN_PREFIX; i < maxOffset; i++) { | 244 for (size_t i = MIN_PREFIX; i < maxOffset; i++) { |
| 245 result[i] &= 1; | 245 result[i] &= 1; |
| 246 } | 246 } |
| 247 } | 247 } |
| 248 | 248 |
| 249 } // namespace android | 249 } // namespace android |
| OLD | NEW |