Show a PDF document in a browser without the menu bar - html

I have a touch screen kiosk that displays a webpage and a pdf document. Can I remove the menu bar? Users must not have "save", "print" and other such features.
Update
random screenshot on flickr - I am refering to the print, back/forward, zoom bar that controls the PDF -- not the browser menu. Sorry for not beeing specific.

OK - you should be able to set up most of that in the pdf document itself.
This is going from the menus in Acrobat Pro 9:
File -> Properties -> Initial View
There are some options there for: Hide menu bar, tool bars, window controls
This has been around in acrobat for a while, so most version should do it.
It is alo possible to set these programmatically if you have the right libraries, but easiest to download a demo of acrobat.

OpenOffice also has options to hide controls and forbid printing under:
File->Export as PDF->User Interface
Unfortunately, you can't modify current PDFs. You'll have to have a Word or OOorg document to export.

You should really use PDF Open Parameters for this.

Good discussion on using IE7 in Kiosk mode:
http://samanathon.com/internet-explorer-7s-kiosk-mode/
If Firefox is on option for you, see this plugin:
R-kiosk
Real Kiosk is a Firefox 2.0 - 3.0 extension that defaults to full screen, disables all menus, toolbars, key commands and right button menus. Alt+Home still takes you home

If you are running a machine with the .net framework you could throw together a windows forms app with an embedded web browser control, which gives you a little more control (how do they go back from pdf without a toolbar or a right click?)
But the quickest option that I have used (done a few touchscreens) is just using IE in kiosk mode, which is easily accomplished with command line switches, and setting that to run fullscreen on windows startup.

u need pdf professional version to do that when you create the pdf file,
File -- Properties -- Initial Vies
check the "Hide menu bar" and "Hide tool bars"
Save
Good Luck

Or just use this open source component and get rid of acrobat reader
http://flexpaper.devaldi.com/

Related

Add space in the bottom of chrome dev console

Each Time I'm using this console I'm struggeling with my mouse to click on the editable line.
So two question :
Is there a way of enlarging this line so it easier to click on it ?
Is there a command to navigate to it ?
The only way to enlarge it is to create a custom theme for DevTools, enable the experiment for using custom themes, and then installing your extension. That way you can get custom CSS into the top-level DevTools scope to modify things.
You may open a bug report on the chromium issue tracker against the DevTools so the team can assess the UX to see if there is anything they should modify internally.

Is it possible to open multiple instances or split view of chrome developer tools tabs?

I want to debug code at the same time as I see what is being sent on the network tab without having to go back and forth between the Network tab and Sources tab. Is there a way to do this as of chrome Version 52.0.2743.82 or Version 54.0.2810.2 canary?
I know that it is possible to log http request in the console which can be visible with other tabs open but I want the actuall networks tab if possible..
Thank you in advance
This is now possible in Chrome 87. Right click Network in the menu and select "Move to bottom"
and it will do this
You can view 'Quick source' while viewing the Network panel (or the other main panels) at the same. This will allow you to view the source and add breakpoints.
However, it's not possible to step through code using the debugging in the split view. Chrome will automatically switch to the Sources tab if you use the shortcuts.
It's also not possible to have an extension running a separate instance of the debugger as the Chrome Debugging Protocol doesn't allow simultaneous clients to be connected.
I will open up a discussion with other Chromium contributors into the feasibility of sharing the debugging controls in the split view. I don't know whether it will or can be done easily. I suspect it's a fair amount of work.
If you would like to set up the split view, as it's useful anyway, go to overflow menu on the right side and select 'More Tools' and then select 'Show console'. This makes sure the panel loads below the main one.
On the left side of the panel that shows, click the overflow menu and select 'Quick source'.
You will now see a small Sources panel.
Since I was referred here from this question, I'll answer here.
In my scenario I need to be able to work on two different source files (under DevTools->Sources) simultaneously, for instance an html and a css file.
My workaround was to work on two separate tabs.
Right click one of them and click 'Open in new tab'.
When the new tab is open press F12 to open DevTools, and dock the two editors side by side (Focus on one and pressing ⊞+→ then leftwards on the other one).
Result:

How to change the locale in chrome browser

I want to change Accept-language request header to anything I wanted in chrome, is there any extension or plugin where I can do it. I want to be able to change locale and language both. Main requirement is changing the locale.
Open chrome, go to chrome://settings/languages
On the left, you should see a list of languages. Use mouse to drag the language you want to the top, that will change the order for the values in Accept-language of requests.
If you still don't see the language you prefer, it may be cookies. Go to cookies and clean it up you should be good.
Feb, 2022 Update:
On Chrome, press F12 to open Developer Tools:
Then, press Esc to open another panel which has Sensors tab:
Finally, you can set the Locale like "ja-JP" by choosing the Location, "Tokyo" as shown below:
If there isn't Sensors tab, you can open it from the 3 dots as shown below:
I use this function for testing internationally launched website.
Based from this thread, you need to bookmark chrome://settings/languages and then Drag and Drop the language to make it default. You have to click on the Display Google Chrome in this Language button and completely restart Chrome.
[on hold: broken in Chrome 72; reported to work in Chrome 71]
The "Quick Language Switcher" extension may help too:
https://chrome.google.com/webstore/detail/quick-language-switcher/pmjbhfmaphnpbehdanbjphdcniaelfie
The Quick Language Switcher extension allows the user to supersede the locale the browser is currently using in favor of the value chosen through the extension.
To see what's your current locale, do
Intl.NumberFormat().resolvedOptions().locale
in Dev Tools > console. (more details)
The top answer here is both outdated, and does NOT work in Mac OS (November 2021).
The official answer is available at:
https://developer.chrome.com/docs/extensions/reference/i18n/#how-to-set-browsers-locale
Windows: Using the UI
Here's how to change the locale using the UI on Google Chrome for Windows:
App icon > Options
Choose the Under the Hood tab
Scroll down to Web Content
Click Change font and language settings
Choose the Languages tab
Use the drop down to set the Google Chrome language
Restart Chrome
Mac OS X
To change the locale on Mac, you use the system preferences.
From the Apple menu, choose System Preferences
Under the Personal section, choose International
Choose your language and location
Restart Chrome
Linux
To change the locale on Linux, first quit Google Chrome. Then, all in one line, set the LANGUAGE environment variable and launch Google Chrome. For example:
LANGUAGE=es ./chrome
Chrome OS
To change the locale on Chrome OS:
From the system tray, choose Settings.
Under the Languages and input section, choose the Language dropdown.
If your language is not listed, click Add languages and add it.
Once added, click the the 3-dot More actions menu item next to your language and choose Display Chrome OS in this language.
Click the Restart button that appears next to the set language to restart Chrome OS.
Use ModHeader Chrome extension.
Or you can try more complex value like Accept-Language: en-US,en;q=0.9,ru;q=0.8,th;q=0.7
There is an article written by the devtools team describing how change the location settings in Chrome for testing purposes: https://developers.google.com/web/tools/chrome-devtools/device-mode/geolocation
The easiest way I found, summarized in a few pictures:
You could skip a few steps (up to step 4) by simply navigating to chrome://settings/languages right away.
I know this is a very old post but I was searching for a solution to define language for chrome without even starting it or update the exe shortcut.
It is possible to force a language and a locale for chrome with the registry on windows.
You need 2 keys to be changed WITH ADMIN RIGHTS :
[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Policies\Google\Chrome]
"ApplicationLocaleValue"="fr"
[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Policies\Google\Chrome\ForcedLanguages]
"1"="fr-FR"
This is forcing the language so all users will not be able to update it with the Chorme UI.
If you need to force a language and be able to modify it with the UI, maybe there is a solution on the official Documentation linked below.
Official Documentation :
ApplicationLocaleValue
ForcedLanguages
Best regards.

How to disable chrome extensions JS when debugging in devtools?

When I add mouse event breakpoint, devtools always jump into extension's JS.
Is there any way to point to my mouse event code directly?
The only way to disable the script (e.g. to avoid side-effects) is by disabling the extension (for instance, by using incognito mode if the extension is not enabled in incognito mode).
If you don't mind the scripts to run, but want to ignore extension code, then you can use the script blackboxing feature of Chrome's devtools.
If you never develop extensions and aren't interested in stepping through it, then open the settings menu of the devtools, click on Blackboxing and then the "Blackbox content scripts" checkbox:
If you only want to selectively ignore files, then you can also right-click on the source of the file that you want to ignore, and click on the "Blackbox Script" contextmenu option. To remove the pattern, go to the "Blackboxing" settings panel as shown before.
I think the simplest way is to open an incognito window (Ctrl-Shift-N) (or Cmd-Shift-N for mac) and debug in there, because then there will be no extensions loaded (by default).
I know what you mean by this question: when debugging, and doing something simple like pausing execution, you always find it breaks into one of the extension's codes instead of the current webpage's code.
open developer tools, then go to settings and then click on ignore list, and check the checkbox for add content script to ignore list, then add this to the ignore list: ^chrome-extension://
If you're using Google Chrome (or any Chromium-based browsers), simply run a new browser instance with a fresh user's data directory.
On Linux:
google-chrome --user-data-dir=$(mktemp -d)
This way, all extensions will be disabled without having to manually switch off/on them.
I like to use Profiles for that.
While changing into incognito mode might help you to disable most of the extensions, some of them might be allowed and still run. For example I have DarkReader and Ublock enabled in incognito mode.
My favorite workaround is to use a "Guest" profile or to create a profile that you can use for debugging. I think it is easier than creating a Framework Ignore List inside of devtools.
How to create a profile: https://support.google.com/chrome/answer/2364824
Example: My debugging profile
First off you should probably review the tutorial on how to debug chrome extensions here:
http://code.google.com/chrome/extensions/tut_debugging.html
When in doubt, you can always use the debugger keyword directly in the JavaScript code where you want to launch the debugger from, like so:
element.addEventListener("mouseover", function() {
debugger;
// some JS handler code...
});
Depending on if your JS is in a popup, background page, or in a content script, you will need make sure you launch the dev tools from the right place.
For a popup, you need to right click on the extension icon and "Inspect Popup" and then from the JavaScript console you would need to run location.reload(true)
For a background page, you need to go to the extensions settings page, chrome://settings/extensions, turn on developer mode, expand the extension in question and click the background page link.
The content script should be visible directly from the page it is loaded onto.

Does extensions work if I save chrome page as application into my desktop?

Does extensions work if I save chrome page as shortcut application?
I've tried but no result.
We know that if we save page as application, there would be no address bar and all other browser buttons.
I've developed simple extension, with no UI, just javascrips running in background.html page. So, as I see no scripts are running in application. But I need them work.
What can I do?
Simply edit the shortcut path and append --enable-extensions.
To edit a Windows 7 pinned taskbar item, right click it then right click the program name and select Properties from the menu.