()
| 99 | } |
| 100 | |
| 101 | pub fn all() -> io::Result<Vec<Display>> { |
| 102 | let server = match x11::Server::default() { |
| 103 | Ok(server) => server, |
| 104 | Err(_) => return Err(io::ErrorKind::ConnectionRefused.into()), |
| 105 | }; |
| 106 | |
| 107 | Ok(x11::Server::displays(server).map(Display).collect()) |
| 108 | } |
| 109 | |
| 110 | pub fn width(&self) -> usize { |
| 111 | self.0.rect().w as usize |
no outgoing calls
no test coverage detected