Re: [Factor-talk] Factor UI and Input Method

2019-04-11 Thread KUSUMOTO Norio
I will post the contents written to github.


I've got stuck.
For example, I use the return key to confirm the conversion string, but I can 
not
operate well because the key input to IM such as return passes over to Factor.

I expected the key input to be received first by the IM, and the app received 
the input that was not consumed, but it seems that the IM can't receive the 
input 
unless the Factor backend sends a key-down event.




--
KUSUMOTO Norio






___
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk


Re: [Factor-talk] Factor UI and Input Method

2019-04-11 Thread KUSUMOTO Norio
> 2019/04/11 7:23、Alexander Ilin のメール:
> 
> nil is f, the canonical false value.

Thank you!

--
KUSUMOTO Norio


> 2019/04/11 7:23、Alexander Ilin のメール:
> 
> nil is f, the canonical false value.
> 
> 10.04.2019, 15:52, "KUSUMOTO Norio" :
>> Hmm, "text" may be a NSAttributedString.
>> I would like to return nil at validAttributesForMarkedText.
>> Can I express nil in the Factor code? How should I write it?
>> 
>> --
>> KUSUMOTO Norio
>> 
>>>  2019/04/10 10:29、KUSUMOTO Norio のメール:
>>> 
>>>  I will post the contents written to github.
>>> 
>>>  I think the replacement from NSTextInput to NSTextInputClient can't solve 
>>> this problem
>>>  unless its methods are implemented appropriately.
>>>  In an opposite way, even with NSTextInput, I anticipate the appropriate 
>>> implementation
>>>  of methods can solve it.
>>> 
>>>  I'm writing a experimental code for it. But I'm in trouble.
>>>  In setMarkedText:selectedRange: , I can't convert text from a NSString to 
>>> a factor string
>>>  by CF>string. I got the error "Unix signal #6 (SIGABRT)".
>>>  The word works fine in insertText: .
>>> 
>>> ! Text input
>>> METHOD: void insertText: id text
>>> [
>>> self window :> window
>>> window [
>>> text CF>string window user-input
>>> ] when
>>> ] ;
>>> 
>>> METHOD: char hasMarkedText [ 0 ] ;
>>> 
>>> METHOD: NSRange markedRange [ 0 0  ] ;
>>> 
>>> METHOD: NSRange selectedRange [ 0 0  ] ;
>>> 
>>>  ! METHOD: void setMarkedText: id text selectedRange: NSRange range [ ] ;
>>> 
>>> METHOD: void setMarkedText: id text selectedRange: Nsrange range
>>>  [
>>> self window :> window
>>> window [
>>>  ! ok --> "abc"
>>>  ! ok --> "xyz"  CF>string
>>>  ! "alien " text class-of "%s " sprintf
>>> text CF>string ! Error Unix signal #6 (SIGABRT)
>>> window world-focus user-input* drop
>>> ] when
>>>  ] ;
>>> 
>>>  --
>>>  KUSUMOTO Norio
>> 
>> ___
>> Factor-talk mailing list
>> Factor-talk@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/factor-talk
> 
> ---=--- 
> Александр
> 
> 
> 
> ___
> Factor-talk mailing list
> Factor-talk@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/factor-talk



___
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk