This commit is contained in:
ZakatTeamI2P 2026-05-20 21:55:38 +04:00
parent f74e3372cd
commit 2816992fcf
2 changed files with 5 additions and 13 deletions

View file

@ -10,7 +10,11 @@ class Window_Message < Window_Selectable
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(16, 336, 608, 128)
if Graphics.width == 1280
super(16, 336, 1248, 128)
else
super(16, 336, 608, 128)
end
self.contents = Bitmap.new(width - 32, height - 32)
Language.register_text_sprite(self.class.name + "_contents", self.contents)
self.visible = false

View file

@ -35,26 +35,14 @@ int screenMain(Config &conf){
Pipe ipc("oneshot-pipe", Pipe::Read);
//int imgFlags = IMG_INIT_PNG;
//if (IMG_Init(imgFlags) != imgFlags)
//{
// showInitError(std::string("Error initializing SDL_image: ") + SDL_GetError());
// SDL_Quit();
//
// return 0;
//}
SDL_Window *win;
win = SDL_CreateWindow("The Journal", SDL_WINDOWPOS_CENTERED, SDL_WINDOWPOS_CENTERED, SDL_WINDOW_RESIZABLE | SDL_WINDOW_TRANSPARENT);
//SDL_SetWindowShape(win, );
if (!win){
showInitError(std::string("Error creating window: ") + SDL_GetError());
return 0;
}
// i have no idea if it works.
//SDL_Surface *shape = SDL_CreateRGBSurface(0, DEFAULT_WIDTH, DEFAULT_HEIGHT, 8, 0, 0, 0, 0);
SDL_Surface *shape = SDL_CreateSurface(DEFAULT_WIDTH, DEFAULT_HEIGHT, SDL_PixelFormat::SDL_PIXELFORMAT_RGBA32);
SDL_Palette *palette = SDL_CreateSurfacePalette(shape);
SDL_SetPaletteColors(palette, &black, 0, 1);