()
| 141 | } |
| 142 | |
| 143 | func ExampleDocument_GetWordAfterCursor() { |
| 144 | d := &Document{ |
| 145 | Text: `Hello! my name is c-bata. |
| 146 | This is a example of Document component. |
| 147 | `, |
| 148 | cursorPosition: len(`Hello! my name is c-bata. |
| 149 | This is a exam`), |
| 150 | } |
| 151 | fmt.Println(d.GetWordAfterCursor()) |
| 152 | // Output: |
| 153 | // ple |
| 154 | } |
| 155 | |
| 156 | func ExampleDocument_GetWordBeforeCursorWithSpace() { |
| 157 | d := &Document{ |
nothing calls this directly
no test coverage detected
searching dependent graphs…