Module: TclTkLib

Defined in:
ext/lib/tk.rb

Class Method Summary collapse

Class Method Details

._encoding=Object



2966
# File 'ext/lib/tk.rb', line 2966

alias _encoding= encoding=

.default_encoding=(name) ⇒ Object



2961
2962
2963
# File 'ext/lib/tk.rb', line 2961

def default_encoding=(name)
  TkCore::INTERP.default_encoding = name
end

.encoding=(name) ⇒ Object



2967
2968
2969
2970
# File 'ext/lib/tk.rb', line 2967

def encoding=(name)
  name = name.name if name.kind_of?(::Encoding) if Tk::WITH_ENCODING
  TkCore::INTERP.encoding = name
end

.encoding_nameObject Also known as: encoding, default_encoding



2972
2973
2974
# File 'ext/lib/tk.rb', line 2972

def encoding_name
  TkCore::INTERP.encoding
end

.encoding_objObject



2978
2979
2980
2981
2982
2983
2984
# File 'ext/lib/tk.rb', line 2978

def encoding_obj
  if Tk::WITH_ENCODING
    Tk::Encoding.tcl2rb_encoding(TkCore::INTERP.encoding)
  else
    TkCore::INTERP.encoding
  end
end

.force_default_encoding=(mode) ⇒ Object



2953
2954
2955
# File 'ext/lib/tk.rb', line 2953

def force_default_encoding=(mode)
  TkCore::INTERP.force_default_encoding = mode
end

.force_default_encoding?Boolean

Returns:

  • (Boolean)


2957
2958
2959
# File 'ext/lib/tk.rb', line 2957

def force_default_encoding?
  TkCore::INTERP.force_default_encoding?
end