Skip to content

Instantly share code, notes, and snippets.

@kennykerr
Created February 8, 2021 21:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kennykerr/0dd9acc8bf0f9b03ce6686759f3e3e2e to your computer and use it in GitHub Desktop.
Save kennykerr/0dd9acc8bf0f9b03ce6686759f3e3e2e to your computer and use it in GitHub Desktop.
use bindings::{windows::win32::intl::*, windows::*};
fn main() -> Result<()> {
initialize_mta()?;
let factory: ISpellCheckerFactory = create_instance(&SpellCheckerFactory)?;
let locale = HString::from("en-US");
let mut supported = FALSE;
unsafe {
factory
.IsSupported(locale.as_wide().as_ptr(), &mut supported.0)
.ok()?;
}
println!("supported: {:?}", supported);
Ok(())
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment