vlang / ui

A cross-platform UI library written in V
MIT License
2.33k stars 152 forks source link

webview.v example and WebKit.h problem #201

Open ManPython opened 4 years ago

ManPython commented 4 years ago

V and UI versions: V 0.1.29 eabc2da OS: W7

What did you do? v run "C:\Users\user.vmodules\ui\examples\webview.v"

What did you expect to see? See some webkit example

What did you see instead?

>v run "C:\Users\user\.vmodules\ui\examples\webview.v"
E:\PROGRAMY\SYSTEM\PROGRAMING\Vlang\v-0.1.29\v\vlib\clipboard\clipboard_windows.c.v:136:15: warning: pointer indexing is only allowed in `unsafe` blocks
  134 |         mut locked := &u16(C.GlobalLock(buf))
  135 |         C.MultiByteToWideChar(C.CP_UTF8, C.MB_ERR_INVALID_CHARS, text.str, text.len + 1, locked, len_required)
  136 |         locked[len_required - 1] = u16(0)
      |               ~~~~~~~~~~~~~~~~~~
  137 |         C.GlobalUnlock(buf)
  138 |     }
==================
  ^~~~~~
C:\Users\user\.vmodules\ui/webview/webview_darwin.m:4:9: fatal error: WebKit/WebKit.h: No such file or directory
 #import <WebKit/WebKit>
         ^~~~~~~~~~~~~~~~~
compilation terminated.
...
==================
(Use `v -cg` to print the entire error message)

builder error:
==================
C error. This should never happen.

If you were not working with C interop, please raise an issue on GitHub:

https://github.com/vlang/v/issues/new/choose

You can also use #help on Discord: https://discord.gg/vlang
  1. WebKit.h is not installed?
  2. Where we can get WebKit.h ?
serkonda7 commented 4 years ago

The webview is currently only implemented on macOS, so you will have to wait until cross-platform implementation.

fxqy commented 4 years ago

Can webview support vue js after cross-platform implementation?