/// Creates a metadata descriptor from metadata.
Creates a metadata descriptor from metadata.
Creates a metadata descriptor from metadata .
pub fn from_metadata(metadata: NativeGraphicsMetadata) -> NativeGraphicsMetadataDescriptor {
        unsafe {
            let c_str = XDisplayString(metadata.display) as *const _;
            let bytes = CStr::from_ptr(c_str).to_bytes();
            NativeGraphicsMetadataDescriptor {
                display: str::from_utf8(bytes).unwrap().to_string(),
            }
        }
    }
pub fn from_metadata ( metadata : NativeGraphicsMetadata ) -> NativeGraphicsMetadataDescriptor { unsafe { let c_str = XDisplayString ( metadata . display ) as * const _ ; let bytes = CStr :: from_ptr ( c_str ) . to_bytes ( ) ; NativeGraphicsMetadataDescriptor { display : str :: from_utf8 ( bytes ) . unwrap ( ) . to_string ( ) , } } }
Creates a metadata descriptor from metadata.
Creates a metadata descriptor from metadata .
metadata
NativeGraphicsMetadata