mirror of https://github.com/Calamitous/iris.git
Fix screen width
Allow interface to use full screen width, while being at least 80 characters wide
This commit is contained in:
parent
854dddb008
commit
e5743e6562
3
iris.rb
3
iris.rb
|
@ -299,7 +299,8 @@ class Message
|
||||||
end
|
end
|
||||||
|
|
||||||
class Display
|
class Display
|
||||||
WIDTH = 80
|
MIN_WIDTH = 80
|
||||||
|
WIDTH = [ENV['COLUMNS'].to_i, `tput cols`.chomp.to_i, MIN_WIDTH].compact.max
|
||||||
|
|
||||||
def self.topic_index_width
|
def self.topic_index_width
|
||||||
Corpus.topics.size.to_s.length
|
Corpus.topics.size.to_s.length
|
||||||
|
|
Loading…
Reference in New Issue