我正在使用胜利本机并有一个带有 VictoryLine 和 VictoryArea 的 VictoryChart 作为孩子,并且想要删除图表的轴。有没有办法通过道具访问它?可能颜色可以设置为透明。
这是一些代码:
<VictoryChart
containerComponent={
<VictoryContainer />
}
>
<VictoryArea
interpolation={interpolation}
data={this.state.data}
/>
<VictoryLine
interpolation={interpolation}
data={this.state.data}
/>
</VictoryChart>
Run Code Online (Sandbox Code Playgroud) 我正在自己写一个shell,我总是收到这个警告"从不兼容的pointertype分配"以获取以下代码(只是重要的部分)
if (first_struct == NULL)
{
first_struct = &parg;
}
else
{
Pargs** temp = first_struct;
while ((*temp)->next != NULL)
temp = &((*temp)->next);<--incompatible pointer type
(*temp)->next = parg;<--incompatible pointer type
}
parg->next = NULL;
Run Code Online (Sandbox Code Playgroud)
对我来说,只有相同的指针类型.
这是结构的代码:
typedef struct
{
struct Pargs* next;
char* command;
char* args[11];
} Pargs;
Run Code Online (Sandbox Code Playgroud)
该结构被声明为以上几行:
Pargs* parg = malloc(sizeof (Pargs));
Run Code Online (Sandbox Code Playgroud)
也许我没有看到自己的失败,但我从几个小时开始看这条线,我不知道为什么这不应该是正确的.
PS:如果有人需要更多代码或信息,请不要犹豫,我还有更多代码或信息;)